diff --git a/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler.php b/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler.php index 0d5b78d497..a1aee18b8c 100644 --- a/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler.php +++ b/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler.php @@ -133,6 +133,7 @@ class DeprecationErrorHandler if ($deprecation->originatesFromAnObject()) { $class = $deprecation->originatingClass(); $method = $deprecation->originatingMethod(); + $msg = $deprecation->getMessage(); if (0 !== error_reporting()) { $group = 'unsilenced'; diff --git a/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler/Deprecation.php b/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler/Deprecation.php index e267a3b8db..17e9510614 100644 --- a/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler/Deprecation.php +++ b/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler/Deprecation.php @@ -133,6 +133,11 @@ class Deprecation return $this->originMethod; } + public function getMessage(): string + { + return $this->message; + } + /** * @param string $utilPrefix *