diff options
| author | Paul Duncan <pabs@pablotron.org> | 2018-09-03 11:08:27 -0400 | 
|---|---|---|
| committer | Paul Duncan <pabs@pablotron.org> | 2018-09-03 11:08:27 -0400 | 
| commit | 3337f692768da6302d0329985f256eaf572f90e0 (patch) | |
| tree | e62c409ecc66dd08492a5ddca2186e3503b2220c | |
| parent | 7b7fdf2723adda17251387ba76a899bbfc9d46fe (diff) | |
| download | zipstream-php-c6f4c87ef0dbcf64784b9d556a88f1c78eca7b53.tar.xz zipstream-php-c6f4c87ef0dbcf64784b9d556a88f1c78eca7b53.zip  | |
fix failing testv0.3.0
| -rw-r--r-- | tests/ArchiveTest.php | 10 | 
1 files changed, 9 insertions, 1 deletions
diff --git a/tests/ArchiveTest.php b/tests/ArchiveTest.php index 8345ee4..393075d 100644 --- a/tests/ArchiveTest.php +++ b/tests/ArchiveTest.php @@ -10,12 +10,20 @@ use Pablotron\ZipStream\StreamWriter;  final class ArchiveTest extends BaseTestCase {    public function testCreate() : void { -    $zip = new ZipStream('test.zip'); +    $zip_path = tempnam('/tmp', 'zipstream-test'); + +    $zip = new ZipStream($zip_path, [ +      'output' => new FileWriter(), +    ]);      $this->assertInstanceOf(        ZipStream::class,        $zip      ); + +    # close archive and remove temp file +    $zip->close(); +    unlink($zip_path);    }    public function testFileWriter() {  | 
