You are here

public function AnnotationFileLoaderTest::testSupports in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/routing/Tests/Loader/AnnotationFileLoaderTest.php \Symfony\Component\Routing\Tests\Loader\AnnotationFileLoaderTest::testSupports()

File

vendor/symfony/routing/Tests/Loader/AnnotationFileLoaderTest.php, line 51

Class

AnnotationFileLoaderTest

Namespace

Symfony\Component\Routing\Tests\Loader

Code

public function testSupports() {
  $fixture = __DIR__ . '/../Fixtures/annotated.php';
  $this
    ->assertTrue($this->loader
    ->supports($fixture), '->supports() returns true if the resource is loadable');
  $this
    ->assertFalse($this->loader
    ->supports('foo.foo'), '->supports() returns true if the resource is loadable');
  $this
    ->assertTrue($this->loader
    ->supports($fixture, 'annotation'), '->supports() checks the resource type if specified');
  $this
    ->assertFalse($this->loader
    ->supports($fixture, 'foo'), '->supports() checks the resource type if specified');
}