Fix reporting unsilenced deprecations from insulated tests

This commit is contained in:
Nicolas Grekas 2019-06-09 16:27:26 +02:00
parent db91042f6b
commit 48093f4a13
2 changed files with 4 additions and 2 deletions

View File

@ -284,7 +284,8 @@ class SymfonyTestsListenerTrait
foreach ($deprecations ? unserialize($deprecations) : array() as $deprecation) {
$error = serialize(array('deprecation' => $deprecation[1], 'class' => $className, 'method' => $test->getName(false), 'triggering_file' => isset($deprecation[2]) ? $deprecation[2] : null));
if ($deprecation[0]) {
@trigger_error($error, E_USER_DEPRECATED);
// unsilenced on purpose
trigger_error($error, E_USER_DEPRECATED);
} else {
@trigger_error($error, E_USER_DEPRECATED);
}

View File

@ -361,7 +361,8 @@ abstract class Client
unlink($deprecationsFile);
foreach ($deprecations ? unserialize($deprecations) : [] as $deprecation) {
if ($deprecation[0]) {
@trigger_error($deprecation[1], E_USER_DEPRECATED);
// unsilenced on purpose
trigger_error($deprecation[1], E_USER_DEPRECATED);
} else {
@trigger_error($deprecation[1], E_USER_DEPRECATED);
}