O'Reilly    
 Published on O'Reilly (http://www.oreilly.com/)
 http://oracle.oreilly.com/utplsql/news/news.html
 See this if you're having trouble printing code examples


A Unit Testing Framework for Oracle PL/SQL-- What's New

by Steven Feuerstein
03/20/2001

utPLSQL Update:
20 March 2001

utPLSQL version 1.5.6 is now available for download and installation! This release of the only unit testing framework for PL/SQL offers a range of significant new features, including:

Here is an example. I create a "dummy" package and then generate a UTP for that package, specifying two test cases. Try it out. You'll like it!


CREATE OR REPLACE PACKAGE genall
IS
   PROCEDURE proc1 (
      val1   IN       NUMBER,
      val2   IN       DATE,
      val3   IN OUT   VARCHAR2,
      val4   IN       BOOLEAN
   );

   FUNCTION func1 (
      val1   IN       NUMBER,
      val2   IN       DATE,
      val3   IN OUT   VARCHAR2,
      val4   IN       BOOLEAN
   )
      RETURN BOOLEAN;
END;
/

DECLARE
   utc   VARCHAR2 (1000)
      := 
'#program name|test case name|message|arguments|result|assertion type
func1|allOK|allOK|1;12/15/1990;abc;true|true|eq
func1|vars|vars|!abc;!sysdate;abc;||isnull';
BEGIN
   utgen.testpkg_from_string ('genall',
      utc,
      output_type_in   => utgen.c_file,
     dir_in           => 'c:\temp'
   );
END;

utPLSQL Update:
7 November 2000

utPLSQL version 1.5.4, released just a month after the initial announcement of this unit-testing framework for Oracle PL/SQL, offers a range of significant new features, including:


Return to The utPLSQL Project

Copyright © 2007 O'Reilly Media, Inc.