X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=vendor%2Fsymfony%2Fserializer%2FTests%2FMapping%2FLoader%2FAnnotationLoaderTest.php;fp=vendor%2Fsymfony%2Fserializer%2FTests%2FMapping%2FLoader%2FAnnotationLoaderTest.php;h=b2e5c69211227442e469122cbfa71ecfc5288bad;hp=d732ee721708b362e347cff705b2b2bb6afe342d;hb=9917807b03b64faf00f6a1f29dcb6eafc454efa5;hpb=aea91e65e895364e460983b890e295aa5d5540a5 diff --git a/vendor/symfony/serializer/Tests/Mapping/Loader/AnnotationLoaderTest.php b/vendor/symfony/serializer/Tests/Mapping/Loader/AnnotationLoaderTest.php index d732ee721..b2e5c6921 100644 --- a/vendor/symfony/serializer/Tests/Mapping/Loader/AnnotationLoaderTest.php +++ b/vendor/symfony/serializer/Tests/Mapping/Loader/AnnotationLoaderTest.php @@ -44,7 +44,7 @@ class AnnotationLoaderTest extends TestCase $this->assertTrue($this->loader->loadClassMetadata($classMetadata)); } - public function testLoadClassMetadata() + public function testLoadGroups() { $classMetadata = new ClassMetadata('Symfony\Component\Serializer\Tests\Fixtures\GroupDummy'); $this->loader->loadClassMetadata($classMetadata); @@ -52,6 +52,16 @@ class AnnotationLoaderTest extends TestCase $this->assertEquals(TestClassMetadataFactory::createClassMetadata(), $classMetadata); } + public function testLoadMaxDepth() + { + $classMetadata = new ClassMetadata('Symfony\Component\Serializer\Tests\Fixtures\MaxDepthDummy'); + $this->loader->loadClassMetadata($classMetadata); + + $attributesMetadata = $classMetadata->getAttributesMetadata(); + $this->assertEquals(2, $attributesMetadata['foo']->getMaxDepth()); + $this->assertEquals(3, $attributesMetadata['bar']->getMaxDepth()); + } + public function testLoadClassMetadataAndMerge() { $classMetadata = new ClassMetadata('Symfony\Component\Serializer\Tests\Fixtures\GroupDummy');