Skip to content

Commit 69e489a

Browse files
committed
[test] add symfony/phpunit-bridge because of depr. error handler
1 parent 710ebff commit 69e489a

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@
1111
"ext-zlib": "*",
1212
"ext-apcu": "*",
1313
"psr/log": "*",
14-
"phpunit/phpunit": "^9.6"
14+
"phpunit/phpunit": "^9.6",
15+
"symfony/phpunit-bridge": "^7.0"
1516
},
1617
"autoload": {
1718
"files": ["autoload.php"]

tests/bootstrap.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
* file that was distributed with this source code.
99
*/
1010

11+
use Symfony\Bridge\PhpUnit\DeprecationErrorHandler;
12+
1113
// setup expected test environment (per check_configuration.php)
1214
ini_set('magic_quotes_runtime', 'off');
1315
ini_set('session.auto_start', 'off');
@@ -65,3 +67,7 @@ function fix_linebreaks($content)
6567
{
6668
return str_replace(array("\r\n", "\n", "\r"), "\n", $content);
6769
}
70+
71+
if ('disabled' !== getenv('SYMFONY_DEPRECATIONS_HELPER')) {
72+
DeprecationErrorHandler::register(getenv('SYMFONY_DEPRECATIONS_HELPER'));
73+
}

0 commit comments

Comments
 (0)