public function testToStringAndEscape() { $pathsToAdd = ['this is a path', 'that', 'needs to be', 'escaped']; foreach ($pathsToAdd as $path) { $this->_purl->getPath()->add($path); } $this->assertEquals('/path/this+is+a+path/that/needs+to+be/escaped', $this->_purl->getPath()->toString()); }
public function testHostPort() { $this->assertEquals('hostname', $this->_purl->getHost()); $this->assertEquals('80', $this->_purl->getPort()); }