Skip to content

Commit

Permalink
Do not crash when test run in child process ends unexpectedly and `--…
Browse files Browse the repository at this point in the history
…log-junit` is used
  • Loading branch information
kubawerlos authored and sebastianbergmann committed Apr 23, 2024
1 parent b2b3555 commit c722fb2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Logging/JUnit/JunitXmlLogger.php
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ public function testPrepared(): void
*/
public function testFinished(Finished $event): void
{
if ($this->preparationFailed) {
if (!$this->prepared || $this->preparationFailed) {
return;
}

Expand Down

0 comments on commit c722fb2

Please sign in to comment.