forked from utPLSQL/utPLSQL
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsuite.html
More file actions
75 lines (67 loc) · 2.2 KB
/
Copy pathsuite.html
File metadata and controls
75 lines (67 loc) · 2.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
</head>
<body>
<!-- Begin utPLSQL Body -->
<!-- $Id$ -->
<h1>Create and Run a Test Suite</h1>
<p>
Usually our applications are composed of multiple packages. To test
our application, we must test all of the packages. utPLSQL makes it easier
for you to do that by offering <a href="defsuite.html">test suites</a>.
</p>
<p>
Here is an example of a script that defines a (partial) test suite for
PL/Vision, a code library available from <a href="http://www.revealnet.com">RevealNet</a>
as part of its Active PL/SQL Knowledge Base:
</p>
<pre>
/*file plvision.tst */
BEGIN
-- Define a test suite for PL/Vision
utsuite.add ('PLVision');
-- Add packages for testing
utpackage.add (
'PLVision', 'PLVstr', dir_in => 'e:\openoracle\utplsql\examples');
utpackage.add (
'PLVision', 'PLVdate', dir_in => 'e:\openoracle\utplsql\examples');
END;
/
</pre>
<p>
This is a very simple test suite definition. I rely on all defaults, but
I specify a location for my test package code. By doing this, utPLSQL will
be able to find my test packages even if the default/current utPLSQL directory
is set to another location.
</p>
<p>
If I want to, I can also specify the order in which packages are tested
by passing a value for the seq_in argument. I can request that the test
code be looked for in the same package as the source code, and so on. Here
is a rewriting of the above sutie creation script that demonstrates these
options:
</p>
<pre>
BEGIN
utsuite.add ('PLVision');
utpackage.add ('PLVision',
'PLVstr',
dir_in => 'e:\openoracle\utplsql\examples',
seq_in => 1,
samepackage_in => TRUE
);
utpackage.add ('PLVision',
'PLVdate',
dir_in => 'e:\openoracle\utplsql\examples',
seq_in => 2,
samepackage_in => TRUE
);
END;
/</pre>
<!-- End utPLSQL Body -->
</body>
</html>