Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit cbe4808

Browse filesBrowse files
[FrameworkBundle][PhpUnitBridge] Configure doctrine/deprecations as expected
1 parent 5bab536 commit cbe4808
Copy full SHA for cbe4808

File tree

2 files changed

+7
-0
lines changed
Filter options

2 files changed

+7
-0
lines changed

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

Copy file name to clipboardExpand all lines: src/Symfony/Bridge/PhpUnit/bin/simple-phpunit.php
+5Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,11 @@
151151
putenv('SYMFONY_DEPRECATIONS_HELPER=disabled');
152152
}
153153

154+
if (!$getEnvVar('DOCTRINE_DEPRECATIONS')) {
155+
putenv('DOCTRINE_DEPRECATIONS=trigger');
156+
$_SERVER['DOCTRINE_DEPRECATIONS'] = $_ENV['DOCTRINE_DEPRECATIONS'] = 'trigger';
157+
}
158+
154159
$COMPOSER = ($COMPOSER = getenv('COMPOSER_BINARY'))
155160
|| file_exists($COMPOSER = $oldPwd.'/composer.phar')
156161
|| ($COMPOSER = rtrim((string) ('\\' === \DIRECTORY_SEPARATOR ? preg_replace('/[\r\n].*/', '', shell_exec('where.exe composer.phar 2> NUL')) : shell_exec('which composer.phar 2> /dev/null'))))

‎src/Symfony/Bundle/FrameworkBundle/FrameworkBundle.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/FrameworkBundle/FrameworkBundle.php
+2Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,8 @@ class FrameworkBundle extends Bundle
9595
*/
9696
public function boot()
9797
{
98+
$_ENV['DOCTRINE_DEPRECATIONS'] = $_SERVER['DOCTRINE_DEPRECATIONS'] ??= 'trigger';
99+
98100
$handler = ErrorHandler::register(null, false);
99101
$this->container->get('debug.error_handler_configurator')->configure($handler);
100102

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.