minor #17632 [FrameworkBundle] Test that ObjectNormalizer is registered (dunglas)
This PR was merged into the 2.7 branch.
Discussion
----------
[FrameworkBundle] Test that ObjectNormalizer is registered
| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | n/a
| License | MIT
| Doc PR | n/a
Commits
-------
129b140
[FrameworkBundle] Test that ObjectNormalizer is registered
This commit is contained in:
commit
11a8524742
@ -18,6 +18,7 @@ use Symfony\Component\DependencyInjection\DefinitionDecorator;
|
||||
use Symfony\Component\DependencyInjection\Loader\ClosureLoader;
|
||||
use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag;
|
||||
use Symfony\Component\DependencyInjection\Reference;
|
||||
use Symfony\Component\Serializer\Normalizer\ObjectNormalizer;
|
||||
use Symfony\Component\Validator\Validation;
|
||||
|
||||
abstract class FrameworkExtensionTest extends TestCase
|
||||
@ -442,6 +443,17 @@ abstract class FrameworkExtensionTest extends TestCase
|
||||
$this->assertTrue($container->has('serializer'));
|
||||
}
|
||||
|
||||
public function testObjectNormalizerRegistered()
|
||||
{
|
||||
$container = $this->createContainerFromFile('full');
|
||||
|
||||
$definition = $container->getDefinition('serializer.normalizer.object');
|
||||
$tag = $definition->getTag('serializer.normalizer');
|
||||
|
||||
$this->assertEquals(ObjectNormalizer::class, $definition->getClass());
|
||||
$this->assertEquals(-1000, $tag[0]['priority']);
|
||||
}
|
||||
|
||||
public function testAssetHelperWhenAssetsAreEnabled()
|
||||
{
|
||||
$container = $this->createContainerFromFile('full');
|
||||
|
Reference in New Issue
Block a user