You are here

public function XmlFileLoaderTest::testThrowExceptionIfDocTypeIsSet in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/validator/Tests/Mapping/Loader/XmlFileLoaderTest.php \Symfony\Component\Validator\Tests\Mapping\Loader\XmlFileLoaderTest::testThrowExceptionIfDocTypeIsSet()

File

vendor/symfony/validator/Tests/Mapping/Loader/XmlFileLoaderTest.php, line 109

Class

XmlFileLoaderTest

Namespace

Symfony\Component\Validator\Tests\Mapping\Loader

Code

public function testThrowExceptionIfDocTypeIsSet() {
  $loader = new XmlFileLoader(__DIR__ . '/withdoctype.xml');
  $metadata = new ClassMetadata('Symfony\\Component\\Validator\\Tests\\Fixtures\\Entity');
  $this
    ->setExpectedException('\\Symfony\\Component\\Validator\\Exception\\MappingException');
  $loader
    ->loadClassMetadata($metadata);
}