public function test_fromIndex() { $zip = new \ZipArchive(); $zip->open(FIXTURES_DIR . '/test.zip'); $entry = ZipArchiveEntry::fromIndex(1, $zip); $this->assertEquals(1, $entry->getIndex()); $this->assertEquals('index.html', $entry->getName()); }
/** * Get the current entry * @return ZipArchiveEntry */ public function current() { return ZipArchiveEntry::fromIndex($this->index, $this->archive); }