Skip to content

Commit d19eb3e

Browse files
peterrehmnicolas-grekas
authored andcommitted
Refactored other PHPUnit method calls to work with namespaced PHPUnit 6
1 parent 34c922c commit d19eb3e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Tests/ParserTest.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,11 @@ public function testSpecifications($file, $expected, $yaml, $comment, $deprecate
4141
if (E_USER_DEPRECATED !== $type) {
4242
restore_error_handler();
4343

44-
return call_user_func_array('PHPUnit_Util_ErrorHandler::handleError', func_get_args());
44+
if (class_exists('PHPUnit_Util_ErrorHandler')) {
45+
return call_user_func_array('PHPUnit_Util_ErrorHandler::handleError', func_get_args());
46+
}
47+
48+
return call_user_func_array('PHPUnit\Util\ErrorHandler::handleError', func_get_args());
4549
}
4650

4751
$deprecations[] = $msg;

0 commit comments

Comments
 (0)