]> git.imager.perl.org - imager.git/blob - t/t92samples.t
move most of README to lib/Imager/Install.pod
[imager.git] / t / t92samples.t
1 #!perl -w
2 # packaging test - make sure we included the samples in the MANIFEST <sigh>
3 use Test::More;
4 use ExtUtils::Manifest qw(maniread);
5
6 # first build a list of samples from samples/README
7 open SAMPLES, "< samples/README"
8   or die "Cannot open samples/README: $!";
9 my @sample_files;
10 while (<SAMPLES>) {
11   chomp;
12   /^\w[\w.-]+\.\w+$/ and push @sample_files, $_;
13 }
14
15 close SAMPLES;
16
17 plan tests => scalar(@sample_files);
18
19 my $manifest = maniread();
20
21 for my $filename (@sample_files) {
22   ok(exists($manifest->{"samples/$filename"}), 
23      "sample file $filename in manifest");
24 }