You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/userguide/running-unit-tests.md
+28Lines changed: 28 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -45,6 +45,10 @@ The **functions** can only be used in SELECT statements. They execute the specif
45
45
## ut.run procedures
46
46
47
47
The examples below illustrate different ways and options to invoke `ut.run` procedures.
48
+
As part of the syntax you can use a wildcard character `*` to call test by part of his name or to call few tests that match a call.
49
+
Schema name is still mandatory and cannot contain a wildcard character whether is a suitepath or object.
50
+
51
+
48
52
49
53
```sql
50
54
alter session set current_schema=hr;
@@ -75,6 +79,14 @@ end;
75
79
Executes all tests from all packages that are on the _com.my_org.my_project_ suitepath.
76
80
Check the [annotations documentation](annotations.md) to find out about suitepaths and how they can be used to organize test packages for your project.
77
81
82
+
```sql
83
+
set serveroutput on
84
+
begin
85
+
ut.run('hr:com*');
86
+
end;
87
+
```
88
+
89
+
Executes all tests from all packages that are on suitepath starting with _com_.
78
90
79
91
```sql
80
92
set serveroutput on
@@ -124,6 +136,22 @@ Using a list of items to execute allows you to execute a fine-grained set of tes
124
136
125
137
List can be passed as a comma separated list or a list of *ut_varchar2_list objects* or as a list within ut_varchar2_list.
126
138
139
+
```sql
140
+
set serveroutput on
141
+
begin
142
+
ut.run('hr.test*');
143
+
end;
144
+
```
145
+
Executes all tests from schema _hr_ starting with name _test_.
146
+
147
+
```sql
148
+
set serveroutput on
149
+
begin
150
+
ut.run('hr.test_apply_bonus.bonus_*');
151
+
end;
152
+
```
153
+
Executes all test procedures from package _hr.test_apply_bonus_ that starting with _bonus_.
0 commit comments