Skip to content

Commit af0b0bb

Browse files
committed
Merge remote-tracking branch 'origin/develop' into feature/publish_test_results_in_pr
2 parents ddf775f + 8c91c7b commit af0b0bb

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+805
-90
lines changed

.github/scripts/xsd/junit_windy.xsd

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
3-
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
2+
<xs:schema
3+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
44
elementFormDefault="qualified"
55
attributeFormDefault="unqualified">
66
<xs:annotation>
@@ -71,10 +71,11 @@ Permission to waive conditions of this license may be requested from Windy Road
7171
<xs:element name="testcase" minOccurs="0" maxOccurs="unbounded">
7272
<xs:complexType>
7373
<xs:choice minOccurs="0">
74-
<xs:element name="error">
75-
<xs:annotation>
76-
<xs:documentation xml:lang="en">Indicates that the test errored. An errored test is one that had an unanticipated problem. e.g., an unchecked throwable; or a problem with the implementation of the test. Contains as a text node relevant data for the error, e.g., a stack trace</xs:documentation>
77-
</xs:annotation>
74+
<xs:element name="skipped" />
75+
<xs:element name="error" minOccurs="0" maxOccurs="1">
76+
<xs:annotation>
77+
<xs:documentation xml:lang="en">Indicates that the test errored. An errored test is one that had an unanticipated problem. e.g., an unchecked throwable; or a problem with the implementation of the test. Contains as a text node relevant data for the error, e.g., a stack trace</xs:documentation>
78+
</xs:annotation>
7879
<xs:complexType>
7980
<xs:simpleContent>
8081
<xs:extension base="pre-string">
@@ -93,9 +94,9 @@ Permission to waive conditions of this license may be requested from Windy Road
9394
</xs:complexType>
9495
</xs:element>
9596
<xs:element name="failure">
96-
<xs:annotation>
97-
<xs:documentation xml:lang="en">Indicates that the test failed. A failure is a test which the code has explicitly failed by using the mechanisms for that purpose. e.g., via an assertEquals. Contains as a text node relevant data for the failure, e.g., a stack trace</xs:documentation>
98-
</xs:annotation>
97+
<xs:annotation>
98+
<xs:documentation xml:lang="en">Indicates that the test failed. A failure is a test which the code has explicitly failed by using the mechanisms for that purpose. e.g., via an assertEquals. Contains as a text node relevant data for the failure, e.g., a stack trace</xs:documentation>
99+
</xs:annotation>
99100
<xs:complexType>
100101
<xs:simpleContent>
101102
<xs:extension base="pre-string">
@@ -192,6 +193,11 @@ Permission to waive conditions of this license may be requested from Windy Road
192193
<xs:documentation xml:lang="en">The total number of tests in the suite that errored. An errored test is one that had an unanticipated problem. e.g., an unchecked throwable; or a problem with the implementation of the test.</xs:documentation>
193194
</xs:annotation>
194195
</xs:attribute>
196+
<xs:attribute name="skipped" type="xs:int" use="optional">
197+
<xs:annotation>
198+
<xs:documentation xml:lang="en">The total number of ignored or skipped tests in the suite.</xs:documentation>
199+
</xs:annotation>
200+
</xs:attribute>
195201
<xs:attribute name="time" type="xs:decimal" use="required">
196202
<xs:annotation>
197203
<xs:documentation xml:lang="en">Time taken (in seconds) to execute the tests in the suite</xs:documentation>
@@ -203,4 +209,4 @@ Permission to waive conditions of this license may be requested from Windy Road
203209
<xs:whiteSpace value="preserve"/>
204210
</xs:restriction>
205211
</xs:simpleType>
206-
</xs:schema>
212+
</xs:schema>

docs/about/authors.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg)
1+
![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg)
22

33
### utPLSQL v3 Major Contributors
44

docs/about/license.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg)
1+
![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg)
22

33
# Version Information
44

docs/about/project-details.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg)
1+
![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg)
22

33
# utPLSQL Project Details
44

docs/about/support.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg)
1+
![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg)
22

33
# How to get support
44

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg)
1+
![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg)
22

33
# Introduction to utPLSQL
44

docs/userguide/advanced_data_comparison.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg)
1+
![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg)
22

33
# Advanced data comparison
44

docs/userguide/annotations.md

Lines changed: 53 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg)
1+
![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg)
22

33
# Annotations
44

@@ -140,7 +140,7 @@ end;
140140
| `--%beforetest([[<owner>.]<package>.]<procedure>[,...])` | Procedure | Denotes that mentioned procedure(s) should be executed before the annotated `%test` procedure. |
141141
| `--%aftertest([[<owner>.]<package>.]<procedure>[,...])` | Procedure | Denotes that mentioned procedure(s) should be executed after the annotated `%test` procedure. |
142142
| `--%rollback(<type>)` | Package/procedure | Defines transaction control. Supported values: `auto`(default) - a savepoint is created before invocation of each "before block" is and a rollback to specific savepoint is issued after each "after" block; `manual` - rollback is never issued automatically. Property can be overridden for child element (test in suite) |
143-
| `--%disabled` | Package/procedure | Used to disable a suite or a test. Disabled suites/tests do not get executed, they are however marked and reported as disabled in a test run. |
143+
| `--%disabled(<reason>)` | Package/procedure | Used to disable a suite, whole context or a test. Disabled suites/contexts/tests do not get executed, they are however marked and reported as disabled in a test run. The reason that will be displayed next to disabled tests is decided based on hierarchy suites -> context -> test |
144144
| `--%context(<description>)` | Package | Denotes start of a named context (sub-suite) in a suite package an optional description for context can be provided. |
145145
| `--%name(<name>)` | Package | Denotes name for a context. Must be placed after the context annotation and before start of nested context. |
146146
| `--%endcontext` | Package | Denotes end of a nested context (sub-suite) in a suite package |
@@ -343,12 +343,13 @@ Finished in .008815 seconds
343343

344344
### Disabled
345345
Marks annotated suite package or test procedure as disabled.
346+
You can provide the reason why the test is disabled that will be displayed in output.
346347

347348
Disabling suite.
348349
```sql
349350
create or replace package test_package as
350351
--%suite(Tests for a package)
351-
--%disabled
352+
--%disabled(Reason for disabling suite)
352353

353354
--%test(Description of tested behavior)
354355
procedure some_test;
@@ -371,13 +372,58 @@ exec ut.run('test_package');
371372
```
372373
```
373374
Tests for a package
374-
Description of tested behavior [0 sec] (DISABLED)
375-
Description of another behavior [0 sec] (DISABLED)
375+
Description of tested behavior [0 sec] (DISABLED - Reason for disabling suite)
376+
Description of another behavior [0 sec] (DISABLED - Reason for disabling suite)
376377
377378
Finished in .001441 seconds
378379
2 tests, 0 failed, 0 errored, 2 disabled, 0 warning(s)
379380
```
380381

382+
Disabling the context(s).
383+
```sql
384+
create or replace package test_package as
385+
--%suite(Tests for a package)
386+
387+
--%context(Context1)
388+
389+
--%test(Description of tested behavior)
390+
procedure some_test;
391+
392+
--%endcontext
393+
394+
--%context(Context2)
395+
396+
--%disabled(Reason for disabling context2)
397+
398+
--%test(Description of another behavior)
399+
procedure other_test;
400+
401+
--%endcontext
402+
end;
403+
/
404+
create or replace package body test_package as
405+
406+
procedure some_test is begin null; end;
407+
408+
procedure other_test is begin null; end;
409+
end;
410+
/
411+
```
412+
413+
```sql
414+
exec ut.run('test_package');
415+
```
416+
```
417+
Tests for a package
418+
Context1
419+
Description of tested behavior [.002 sec]
420+
Context2
421+
Description of another behavior [0 sec] (DISABLED - Reason for disabling context2)
422+
423+
Finished in .005079 seconds
424+
2 tests, 0 failed, 0 errored, 1 disabled, 0 warning(s)
425+
```
426+
381427
Disabling individual test(s).
382428
```sql
383429
create or replace package test_package as
@@ -387,7 +433,7 @@ create or replace package test_package as
387433
procedure some_test;
388434

389435
--%test(Description of another behavior)
390-
--%disabled
436+
--%disabled(Reason for disabling test)
391437
procedure other_test;
392438
end;
393439
/
@@ -406,7 +452,7 @@ exec ut.run('test_package');
406452
```
407453
Tests for a package
408454
Description of tested behavior [.004 sec]
409-
Description of another behavior [0 sec] (DISABLED)
455+
Description of another behavior [0 sec] (DISABLED - Reason for disabling test)
410456
411457
Finished in .005868 seconds
412458
2 tests, 0 failed, 0 errored, 1 disabled, 0 warning(s)

docs/userguide/best-practices.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg)
1+
![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg)
22

33
# Best Practices
44

docs/userguide/coverage.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg)
1+
![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg)
22

33
# Coverage
44
utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database.

0 commit comments

Comments
 (0)