4 if (my $head = `git rev-parse HEAD`) {
5 plan skip_all => "Test disabled until after merge"
6 if $head ne `git rev-parse master`;
8 die "\n\n=================\n!!! Fix the test and remove temporary header !!!\n=================\n\n";
11 eval "use Pod::Coverage 0.19";
12 plan skip_all => 'Pod::Coverage 0.19 required' if $@;
13 eval "use Test::Pod::Coverage 1.04";
14 plan skip_all => 'Test::Pod::Coverage 1.04 required' if $@;
16 plan skip_all => 'set TEST_POD to enable this test'
17 unless ( $ENV{TEST_POD} || -e 'MANIFEST.SKIP' );
19 my @modules = sort { $a cmp $b } ( Test::Pod::Coverage::all_modules() );
20 plan tests => scalar(@modules);
22 # Since this is about checking documentation, a little documentation
23 # of what this is doing might be in order...
24 # The exceptions structure below is a hash keyed by the module
25 # name. The value for each is a hash, which contains one or more
26 # (although currently more than one makes no sense) of the following
28 # skip => a true value means this module is not checked
29 # ignore => array ref containing list of methods which
30 # do not need to be documented.
38 'SQL::Abstract::Test' => { skip => 1 },
39 'DBIx::Class::Storage::Debug::PrettyPrint' => { skip => 1 },
42 foreach my $module (@modules) {
45 skip "$module - No user visible methods",
47 if ( $exceptions->{$module}{skip} );
49 # build parms up from ignore list
52 [ map { qr/^$_$/ } @{ $exceptions->{$module}{ignore} } ]
53 if exists( $exceptions->{$module}{ignore} );
55 # run the test with the potentially modified parm set
56 pod_coverage_ok( $module, $parms, "$module POD coverage" );