File: 17_bug_73797.t

package info (click to toggle)
libarchive-zip-perl 1.39-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 788 kB
  • ctags: 430
  • sloc: perl: 4,624; makefile: 7
file content (23 lines) | stat: -rw-r--r-- 570 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/usr/bin/perl

use strict;

BEGIN {
    $|  = 1;
    $^W = 1;
}
use Archive::Zip qw( :ERROR_CODES );
use Test::More tests => 4;

use t::common;

my $zip = Archive::Zip->new();
isa_ok( $zip, 'Archive::Zip' );
my $dir = $ENV{ADTTMP} ? "debian/t/data" : "t/data";
is( $zip->read("$dir/jar.zip"), AZ_OK, 'Read file' );
is($zip->writeToFileNamed(OUTPUTZIP), AZ_OK, 'Wrote file');

my ($status, $zipout) = testZip();
# STDERR->print("status= $status, out=$zipout\n");
skip( "test zip doesn't work", 1 ) if $testZipDoesntWork;
is( $status, 0, "output zip isn't corrupted" );