Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit cba70a6

Browse files
bug #39226 [PhpUnitBridge] Fix disabling DeprecationErrorHandler from PHPUnit configuration file (fancyweb)
This PR was merged into the 4.4 branch. Discussion ---------- [PhpUnitBridge] Fix disabling DeprecationErrorHandler from PHPUnit configuration file | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | #38239 | License | MIT | Doc PR | - The linked issue description is right, the bridge's bootstrap is hit before the env variables from the phpunit.xml file are read and set. So the easiest solution is to read it ourselves in the root script (like we already do for some of them). Commits ------- 41158b8 [PhpUnitBridge] Fix disabling DeprecationErrorHandler from phpunit configuration file
2 parents 1ea5a8c + 41158b8 commit cba70a6

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Symfony/Bridge/PhpUnit/bin/simple-phpunit.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,10 @@
146146
}
147147
}
148148

149+
if ('disabled' === $getEnvVar('SYMFONY_DEPRECATIONS_HELPER')) {
150+
putenv('SYMFONY_DEPRECATIONS_HELPER=disabled');
151+
}
152+
149153
$COMPOSER = file_exists($COMPOSER = $oldPwd.'/composer.phar')
150154
|| ($COMPOSER = rtrim('\\' === \DIRECTORY_SEPARATOR ? preg_replace('/[\r\n].*/', '', `where.exe composer.phar`) : `which composer.phar 2> /dev/null`))
151155
|| ($COMPOSER = rtrim('\\' === \DIRECTORY_SEPARATOR ? preg_replace('/[\r\n].*/', '', `where.exe composer`) : `which composer 2> /dev/null`))

0 commit comments

Comments
 (0)