Beispiel #1
0
 public function testLinkFunctions()
 {
     $link = new Link($this->link);
     $this->assertEquals('www.moviman.com', $link->getHost());
     $this->assertEquals('/firstpath/secondpath/image.jpg', $link->getPath());
     $this->assertEquals(33, $link->getQueryParameter('code'));
     $link->addQueryParameter('data', 'myData');
     $this->assertEquals('myData', $link->getQueryParameter('data'));
     $link->removeQueryParameter('data');
     $this->assertEquals(null, $link->getQueryParameter('data'));
     $link->addQueryParameter('data', 'myData');
     $this->assertEquals('http://*****:*****@www.moviman.com:2096/firstpath/secondpath/image.jpg?code=33&link=44&data=myData#my_format', (string) $link);
 }