You are here

public function ClassMetadataFactoryTest::testHasMetadataFor in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/serializer/Tests/Mapping/Factory/ClassMetadataFactoryTest.php \Symfony\Component\Serializer\Tests\Mapping\Factory\ClassMetadataFactoryTest::testHasMetadataFor()

File

vendor/symfony/serializer/Tests/Mapping/Factory/ClassMetadataFactoryTest.php, line 39

Class

ClassMetadataFactoryTest
@author Kévin Dunglas <dunglas@gmail.com>

Namespace

Symfony\Component\Serializer\Tests\Mapping\Factory

Code

public function testHasMetadataFor() {
  $factory = new ClassMetadataFactory(new AnnotationLoader(new AnnotationReader()));
  $this
    ->assertTrue($factory
    ->hasMetadataFor('Symfony\\Component\\Serializer\\Tests\\Fixtures\\GroupDummy'));
  $this
    ->assertTrue($factory
    ->hasMetadataFor('Symfony\\Component\\Serializer\\Tests\\Fixtures\\GroupDummyParent'));
  $this
    ->assertTrue($factory
    ->hasMetadataFor('Symfony\\Component\\Serializer\\Tests\\Fixtures\\GroupDummyInterface'));
  $this
    ->assertFalse($factory
    ->hasMetadataFor('Dunglas\\Entity'));
}