Permalink
Browse files

Test Zip specific methods

though there isn't much that isn't tested in archive.t
  • Loading branch information...
rwstauner committed Aug 17, 2011
1 parent c4c956b commit bfec76f4ea28542a1eb62e6f373db1b1f57bfdb2
Showing with 21 additions and 0 deletions.
  1. +21 −0 t/zip.t
View
21 t/zip.t
@@ -0,0 +1,21 @@
+use strict;
+use warnings;
+use Test::More 0.96;
+
+my $mod = 'Dist::Metadata::Zip';
+eval "require $mod" or die $@;
+
+my $base = 'corpus/Dist-Metadata-Test-NoMetaFile-0.1';
+
+# test that instantiating this class directly does not negotiate type
+new_ok($mod => [file => "$base.tgz"]);
+
+my $file = "$base.zip";
+my $zip = new_ok($mod => [file => $file]);
+
+# file_content, and find_files tested in t/archive.t
+
+# read_archive
+isa_ok($zip->read_archive($file), 'Archive::Zip');
+
+done_testing;

0 comments on commit bfec76f

Please sign in to comment.