8000 [PhpUnitBridge] Catch deprecation error handler by cvilleger · Pull Request #26794 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[PhpUnitBridge] Catch deprecation error handler #26794

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
[PhpUnitBridge] Catch deprecation error handler
  • Loading branch information
cvilleger authored and nicolas-grekas committed Apr 4, 2018
commit f40f181167d147efd52ba118cd090043803b5b19
4 changes: 2 additions & 2 deletions src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ public static function register($mode = 0)
}

if (isset($trace[$i]['object']) || isset($trace[$i]['class'])) {
if (isset($trace[$i]['class']) && in_array($trace[$i]['class'], array('Symfony\Bridge\PhpUnit\SymfonyTestsListener', 'Symfony\Bridge\PhpUnit\Legacy\SymfonyTestsListener'), true)) {
if (isset($trace[$i]['class']) && 0 === strpos($trace[$i]['class'], 'Symfony\Bridge\PhpUnit\Legacy\SymfonyTestsListenerFor')) {
$parsedMsg = unserialize($msg);
$msg = $parsedMsg['deprecation'];
$class = $parsedMsg['class'];
Expand Down Expand Up @@ -216,7 +216,7 @@ public static function register($mode = 0)

$groups = array('unsilenced', 'remaining');
if (DeprecationErrorHandler::MODE_WEAK_VENDORS === $mode) {
$groups[] = 'remaining vendor';
$groups[] = 'remaining vendor';
}
array_push($groups, 'legacy', 'other');

Expand Down
0