You are here

public function ChainRouterTest::testWarmup in Zircon Profile 8

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

File

vendor/symfony-cmf/routing/Tests/Routing/ChainRouterTest.php, line 628

Class

ChainRouterTest

Namespace

Symfony\Cmf\Component\Routing\Tests\Routing

Code

public function testWarmup() {
  $dir = 'test_dir';
  list($low) = $this
    ->createRouterMocks();
  $low
    ->expects($this
    ->never())
    ->method('warmUp');
  $high = $this
    ->getMock('Symfony\\Cmf\\Component\\Routing\\Tests\\Routing\\WarmableRouterMock');
  $high
    ->expects($this
    ->once())
    ->method('warmUp')
    ->with($dir);
  $this->router
    ->add($low, 10);
  $this->router
    ->add($high, 100);
  $this->router
    ->warmUp($dir);
}