File tree 1 file changed +7
-1
lines changed
tests/unit/Codeception/Module
1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 12
12
use PHPUnit \Framework \AssertionFailedError ;
13
13
use PHPUnit \Framework \Constraint \IsEqual ;
14
14
use PHPUnit \Framework \IncompleteTestError ;
15
+ use PHPUnit \Framework \SkippedTestError ;
15
16
use PHPUnit \Framework \SkippedWithMessageException ;
17
+ use PHPUnit \Runner \Version as PHPUnitVersion ;
16
18
use RuntimeException ;
17
19
use stdClass ;
18
20
@@ -280,8 +282,12 @@ public function testMarkTestIncomplete()
280
282
281
283
public function testMarkTestSkipped ()
282
284
{
283
- $ this ->expectException (SkippedWithMessageException::class);
284
285
$ this ->expectExceptionMessage ('foobar ' );
286
+ if (PHPUnitVersion::series () < 10 ) {
287
+ $ this ->expectException (SkippedTestError::class);
288
+ } else {
289
+ $ this ->expectException (SkippedWithMessageException::class);
290
+ }
285
291
286
292
$ this ->module ->markTestSkipped ('foobar ' );
287
293
}
You can’t perform that action at this time.
0 commit comments