public function testExtract() { $dir = OC::$SERVERROOT . '/tests/data'; $this->instance = $this->getExisting(); $tmpDir = OCP\Files::tmpFolder(); $this->instance->extract($tmpDir); $this->assertEquals(true, file_exists($tmpDir . 'lorem.txt')); $this->assertEquals(true, file_exists($tmpDir . 'dir/lorem.txt')); $this->assertEquals(true, file_exists($tmpDir . 'logo-wide.png')); $this->assertEquals(file_get_contents($dir . '/lorem.txt'), file_get_contents($tmpDir . 'lorem.txt')); OCP\Files::rmdirr($tmpDir); }