Exemple #1
0
 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());
 }
Exemple #2
0
 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());
 }
Exemple #3
0
 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());
 }