public function testDirName() { $path = new Path('/dir/base.ext'); $this->assertEquals('/dir', $path->dirName()); $path->dirName('/other'); $this->assertEquals('/other/base.ext', $path->name()); }