function testRelativeUrlPart() { $Request = $this->getMock('AkRequest', array('getRelativeUrlRoot')); $Request->expects($this->any())->method('getRelativeUrlRoot')->will($this->returnValue('/subfolder')); $url = new AkUrl('/author/martin'); $url->setOptions(array('skip_relative_url_root' => false, 'relative_url_root' => '/subfolder')); $this->assertEquals('/subfolder/author/martin', $url->path()); }
public function testRelativeUrlPart() { $Request = $this->partialMock('AkRequest', array('getRelativeUrlRoot')); $Request->returnsByValue('getRelativeUrlRoot', '/subfolder'); $url = new AkUrl('/author/martin'); $url->setOptions(array('skip_relative_url_root' => false, 'relative_url_root' => '/subfolder')); $this->assertEqual('/subfolder/author/martin', $url->path()); }
function testRelativeUrlPart() { $url = new AkUrl('/author/martin'); $url->setOptions(array('skip_relative_url_root' => false, 'relative_url_root' => '/subfolder')); $this->assertEquals('/subfolder/author/martin', $url->path()); }