Example #1
0
 public function testPath()
 {
     $app = new UrlGeneratorApplication();
     $app['url_generator'] = $this->getMockBuilder('Symfony\\Component\\Routing\\Generator\\UrlGeneratorInterface')->disableOriginalConstructor()->getMock();
     $app['url_generator']->expects($this->once())->method('generate')->with('foo', array(), UrlGeneratorInterface::ABSOLUTE_PATH);
     $app->path('foo');
 }
 public function createApplication()
 {
     $app = new UrlGeneratorApplication();
     $app->register(new UrlGeneratorServiceProvider());
     return $app;
 }