Output subroutines missing POD regardless of coverage threshold.

Fix the threshold to work correctly based on ENV.
This commit is contained in:
Colin Kuskie 2009-04-02 16:58:38 +00:00
parent ae4917a644
commit ae3b94c242

View file

@ -18,8 +18,8 @@ use Pod::Coverage;
use File::Find;
use File::Spec;
my $threshold = $ENV{POD_COVERAGE} ? 0.75
: $ENV{POD_COVERAGE} == 2 ? 0.9999
my $threshold = $ENV{POD_COVERAGE} == 2 ? 0.9999
: $ENV{POD_COVERAGE} ? 0.75
: 0;
my @modules = ();
@ -37,7 +37,7 @@ foreach my $package (sort @modules) {
SKIP: {
skip "No subroutines found by Devel::Symdump for $package", 1 if $goodReason;
ok($coverage, sprintf "%s has %d%% POD coverage", $package, $pc->coverage*100);
if (!$coverage && $ENV{POD_COVERAGE} ==2) {
if (!$coverage && $ENV{POD_COVERAGE}) {
diag Dumper [$pc->naked];
}
}