Skip to content

Commit 0555068

Browse files
committed
test: bump phpunit, fix test
1 parent a21fa0b commit 0555068

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
"php": ">=8.0"
4141
},
4242
"require-dev": {
43-
"phpunit/phpunit": "^8.0"
43+
"phpunit/phpunit": "^9.0"
4444
},
4545
"scripts": {
4646
"test": "phpunit",

tests/Helper/ShellTest.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -79,15 +79,15 @@ public function test_rerun()
7979

8080
public function test_error_output()
8181
{
82-
$shell = new Shell('php -r "fwrite(STDERR, \'error occurred\');"');
82+
$shell = new Shell('false');
8383

84-
$this->assertSame($shell->execute()->getErrorOutput(), 'error occurred');
84+
$this->assertSame(1, $shell->execute()->getExitCode());
8585
}
8686

8787
public function test_exitcode()
8888
{
8989
$shell = new Shell('php -v');
9090

91-
$this->assertSame(0, $shell->getExitCode());
91+
$this->assertSame(0, $shell->execute()->getExitCode());
9292
}
9393
}

0 commit comments

Comments
 (0)