protected mockRouter ( string $url ) : Symfony\Component\Routing\RouterInterface | PHPUnit_Framework_MockObject_MockObject | ||
$url | string | |
리턴 | Symfony\Component\Routing\RouterInterface | PHPUnit_Framework_MockObject_MockObject |
protected function mockRouter($url)
{
$router = $this->getMock('Symfony\\Component\\Routing\\RouterInterface');
$router->expects($this->any())->method('generate')->willReturn($url);
return $router;
}