You are here

public function ContentAwareGeneratorTest::testGenerateEmptyRouteString in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony-cmf/routing/Tests/Routing/ContentAwareGeneratorTest.php \Symfony\Cmf\Component\Routing\Tests\Routing\ContentAwareGeneratorTest::testGenerateEmptyRouteString()

File

vendor/symfony-cmf/routing/Tests/Routing/ContentAwareGeneratorTest.php, line 87

Class

ContentAwareGeneratorTest

Namespace

Symfony\Cmf\Component\Routing\Tests\Routing

Code

public function testGenerateEmptyRouteString() {
  $this->provider
    ->expects($this
    ->never())
    ->method('getRouteByName');
  $this->contentDocument
    ->expects($this
    ->once())
    ->method('getRoutes')
    ->will($this
    ->returnValue(array(
    $this->routeDocument,
  )));
  $this->routeDocument
    ->expects($this
    ->once())
    ->method('compile')
    ->will($this
    ->returnValue($this->routeCompiled));
  $this
    ->assertEquals('result_url', $this->generator
    ->generate($this->contentDocument));
}