File: 2-pluggable.t

package info (click to toggle)
libmodule-scandeps-perl 0.62-1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 180 kB
  • ctags: 114
  • sloc: perl: 1,811; makefile: 43
file content (28 lines) | stat: -rw-r--r-- 498 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
24
25
26
27
28
#!/usr/bin/perl

use Test;
BEGIN { plan tests => 3 }

use Module::ScanDeps;

use lib qw(t/data);

if (eval {require Module::Pluggable}) {
   my $map = scan_deps(
      files   => ['t/data/Foo.pm'],
      recurse => 1,
   );
   
   ok(exists $map->{'Module/Pluggable.pm'});
   ok(exists $map->{'Foo/Plugin/Bar.pm'});
   ok(exists $map->{'Foo/Plugin/Baz.pm'});

} else {
   print "# Module::Pluggable not installed, skipping all tests\n";
   # Skip tests
   for (1..3) {
      ok(1);
   }
}

__END__