minor #33868 Skip the intl notice if run with phpunit (jakzal)
This PR was squashed before being merged into the 5.0-dev branch (closes #33868).
Discussion
----------
Skip the intl notice if run with phpunit
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | no
| New feature? | no
| Deprecations? | no
| Tickets | Re #33825
| License | MIT
| Doc PR | -
Commits
-------
25461b358c
Skip the intl notice if run with phpunit
This commit is contained in:
commit
53f86271e6
@ -211,7 +211,7 @@ class FrameworkExtension extends Extension
|
|||||||
->addError('You cannot use the "slugger" service since the Translation contracts are not installed. Try running "composer require symfony/translation".');
|
->addError('You cannot use the "slugger" service since the Translation contracts are not installed. Try running "composer require symfony/translation".');
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!\extension_loaded('intl')) {
|
if (!\extension_loaded('intl') && !\defined('PHPUNIT_COMPOSER_INSTALL')) {
|
||||||
@trigger_error('Please install the "intl" PHP extension for best performance.', E_USER_DEPRECATED);
|
@trigger_error('Please install the "intl" PHP extension for best performance.', E_USER_DEPRECATED);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -16,6 +16,9 @@ namespace Symfony\Bundle\FrameworkBundle\Tests\Functional;
|
|||||||
*/
|
*/
|
||||||
class SluggerLocaleAwareTest extends AbstractWebTestCase
|
class SluggerLocaleAwareTest extends AbstractWebTestCase
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* @requires extension intl
|
||||||
|
*/
|
||||||
public function testLocalizedSlugger()
|
public function testLocalizedSlugger()
|
||||||
{
|
{
|
||||||
$kernel = static::createKernel(['test_case' => 'Slugger', 'root_config' => 'config.yml']);
|
$kernel = static::createKernel(['test_case' => 'Slugger', 'root_config' => 'config.yml']);
|
||||||
|
Reference in New Issue
Block a user