File tree 2 files changed +18
-1
lines changed
2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -76,7 +76,8 @@ class XrayReporter implements Reporter {
76
76
} ;
77
77
78
78
// Set Test Error
79
- if ( result . errors . length > 0 ) {
79
+ const pwStepsExists = result . steps . some ( step => step . category . includes ( "test.step" ) ) ;
80
+ if ( result . errors . length > 0 && ! pwStepsExists ) {
80
81
xrayTestData . comment = JSON . stringify ( result . errors ) ;
81
82
} else {
82
83
await Promise . all (
Original file line number Diff line number Diff line change
1
+ import { test , expect } from '@playwright/test' ;
2
+
3
+ test ( 'TES-49 | test with playwright steps' , async ( { page } ) => {
4
+
5
+ await test . step ( 'Step 1' , async ( ) => {
6
+ expect ( true ) . toBe ( true ) ;
7
+ } ) ;
8
+
9
+ await test . step ( 'Step 2' , async ( ) => {
10
+ expect ( true ) . toBe ( true ) ;
11
+ } ) ;
12
+
13
+ await test . step ( 'Step 3' , async ( ) => {
14
+ expect ( false ) . toBe ( true ) ;
15
+ } ) ;
16
+ } ) ;
You can’t perform that action at this time.
0 commit comments