fixed deprecation summary and missing error_reporting() in tests
This commit is contained in:
parent
50ed09ed4a
commit
367184a6d7
@ -33,15 +33,15 @@ class DeprecationErrorHandler
|
||||
return PHPUnit_Util_ErrorHandler::handleError($type, $msg, $file, $line, $context);
|
||||
}
|
||||
|
||||
$trace = debug_backtrace(PHP_VERSION_ID >= 50400 ? DEBUG_BACKTRACE_IGNORE_ARGS : false);
|
||||
$trace = debug_backtrace(PHP_VERSION_ID >= 50400 ? DEBUG_BACKTRACE_IGNORE_ARGS | DEBUG_BACKTRACE_PROVIDE_OBJECT : true);
|
||||
|
||||
$i = count($trace);
|
||||
while (isset($trace[--$i]['class']) && ('ReflectionMethod' === $trace[$i]['class'] || 0 === strpos($trace[$i]['class'], 'PHPUnit_'))) {
|
||||
// No-op
|
||||
}
|
||||
|
||||
if (isset($trace[$i]['class'])) {
|
||||
$class = $trace[$i]['class'];
|
||||
if (isset($trace[$i]['object']) || isset($trace[$i]['class'])) {
|
||||
$class = isset($trace[$i]['object']) ? get_class($trace[$i]['object']) : $trace[$i]['class'];
|
||||
$method = $trace[$i]['function'];
|
||||
|
||||
$type = 0 === strpos($method, 'testLegacy') || 0 === strpos($method, 'provideLegacy') || strpos($class, '\Legacy') ? 'legacy' : 'remaining';
|
||||
|
Reference in New Issue
Block a user