public function setContext(RequestContext $context) { $this->context = $context; }
public function testAbsoluteUrlWithExtraParameters() { $this->routeCollection->add('test', new Route('/testing')); $this->generator->setContext(array('base_url' => '/app.php', 'method' => 'GET', 'host' => 'localhost', 'port' => 80, 'is_secure' => false)); $url = $this->generator->generate('test', array('foo' => 'bar'), true); $this->assertEquals('http://localhost/app.php/testing?foo=bar', $url); }