1
0
Fork 0
mirror of https://github.com/composer/composer synced 2025-05-09 00:22:53 +00:00

Fix more warnings

This commit is contained in:
Jordi Boggiano 2020-09-11 11:27:26 +02:00
parent 711d4792ce
commit d942c65e0c
No known key found for this signature in database
GPG key ID: 7BBD42C429EC80BC
10 changed files with 22 additions and 18 deletions

View file

@ -35,7 +35,11 @@ class ErrorHandlerTest extends TestCase
*/
public function testErrorHandlerCaptureNotice()
{
$this->setExpectedException('\ErrorException', 'Undefined index: baz');
if (PHP_VERSION_ID >= 80000) {
$this->setExpectedException('\ErrorException', 'Undefined array key "baz"');
} else {
$this->setExpectedException('\ErrorException', 'Undefined index: baz');
}
$array = array('foo' => 'bar');
$array['baz'];