/** * @param Phar $phar */ public function removePhar(Phar $phar) { $pharNode = $this->getFirstMatchingPharNode($phar->getName(), $phar->getVersion()); unlink($this->getPharDestination($phar->getFile())); $pharNode->parentNode->removeChild($pharNode); $this->save(); }
/** * @dataProvider fileProvider * * @param File $file */ public function testGetFile(File $file) { $phar = new Phar('foo', new Version('1.0.0'), $file); $this->assertEquals($file, $phar->getFile()); }