public function testCanExtractZipFiles() { $format = new Format\Zip(); if (false === $this->distill->isFormatSupported($format)) { $this->markTestSkipped('zip files are not supported'); } $target = $this->getTemporaryPath(); $this->clearTemporaryPath(); $response = $this->distill->extract($this->filesPath . 'file_ok.zip', $target, $format); $this->assertTrue($response); $this->checkDirectoryFiles($target, $this->filesPath . '/uncompressed'); $this->clearTemporaryPath(); }
public function testCanExtractChainedFiles() { $format1 = new Format\Simple\Zip(); $format2 = new Format\Simple\Xz(); if (false === $this->distill->isFormatSupported($format1)) { $this->markTestSkipped('zip files are not supported'); } if (false === $this->distill->isFormatSupported($format2)) { $this->markTestSkipped('xz files are not supported'); } $target = $this->getTemporaryPath(); $this->clearTemporaryPath(); $response = $this->distill->extract($this->filesPath . 'file_ok.zip.xz', $target); $this->assertTrue($response); $this->assertUncompressed($target, 'file_ok.zip.xz'); $this->clearTemporaryPath(); }