diff options
Diffstat (limited to 'gnu/usr.bin/perl/cpan/IO-Compress/t/010examples-zlib.t')
-rwxr-xr-x | gnu/usr.bin/perl/cpan/IO-Compress/t/010examples-zlib.t | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/gnu/usr.bin/perl/cpan/IO-Compress/t/010examples-zlib.t b/gnu/usr.bin/perl/cpan/IO-Compress/t/010examples-zlib.t index 70e71410884..712c0b49343 100755 --- a/gnu/usr.bin/perl/cpan/IO-Compress/t/010examples-zlib.t +++ b/gnu/usr.bin/perl/cpan/IO-Compress/t/010examples-zlib.t @@ -66,8 +66,12 @@ EOM my @hello2 = grep(s/$/\n/, split(/\n/, $hello2)) ; -my ($file1, $file2, $stderr) ; -my $lex = new LexFile $file1, $file2, $stderr ; +my $file1 = "hello1.gz" ; +my $file2 = "hello2.gz" ; +my $stderr = "err.out" ; + +for ($file1, $file2, $stderr) { 1 while unlink $_ } ; + gzip \$hello1 => $file1 ; gzip \$hello2 => $file2 ; @@ -77,8 +81,8 @@ sub check my $command = shift ; my $expected = shift ; - my $lex = new LexFile my $stderr ; - + my $stderr = 'err.out'; + 1 while unlink $stderr; my $cmd = "$command 2>$stderr"; my $stdout = `$cmd` ; @@ -133,3 +137,9 @@ for ($file1, $file2, $stderr) { 1 while unlink $_ } ; title "gzcat" ; check "$Perl ${examples}/gzcat $file2", $hello1 ; } + +END +{ + for ($file1, $file2, $stderr) { 1 while unlink $_ } ; +} + |