Skip to content

Commit 91a0a66

Browse files
Merge branch '10.3'
2 parents 27e37b9 + 3dc7df7 commit 91a0a66

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

src/Framework/TestCase.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -671,6 +671,10 @@ final public function runBare(): void
671671
$e->getMessage(),
672672
);
673673
} catch (AssertionError|AssertionFailedError $e) {
674+
if (!$this->wasPrepared) {
675+
$this->wasPrepared = true;
676+
}
677+
674678
$this->status = TestStatus::failure($e->getMessage());
675679

676680
$emitter->testFailed(

tests/end-to-end/regression/5493.phpt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
--TEST--
22
https://github.com/sebastianbergmann/phpunit/issues/5493
3-
--XFAIL--
4-
https://github.com/sebastianbergmann/phpunit/issues/5493
53
--FILE--
64
<?php declare(strict_types=1);
75
$_SERVER['argv'][] = '--do-not-cache-result';
@@ -23,7 +21,7 @@ Time: %s, Memory: %s
2321
There was 1 failure:
2422

2523
1) PHPUnit\TestFixture\Issue5493\Issue5493Test::testOne
26-
Failed asserting that true is false.
24+
Failed asserting that false is true.
2725

2826
%sIssue5493Test.php:19
2927

0 commit comments

Comments
 (0)