Subject: | 00-pod-coverage.t plans twice and fails when Pod::Coverage is not installed |
t/00-pod-coverage.t in Graphics::ColorNames fails when Pod::Coverage is
not installed. The attachment file diff works correctly for `make test`
in both cases. -- MARK --
Running make test
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e"
"test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00-pod-coverage......You tried to plan twice at t/00-pod-coverage.t
line 8.
# Looks like your test died before it could output anything.
t/00-pod-coverage...... Dubious, test returned 255 (wstat 65280, 0xff00)
Failed 6/6 subtests
t/00-pod...............skipped: Test::Pod 1.00 required
t/00-Prereqs...........skipped: Test::Prereq required to test
dependencies
t/01-ColorNames........ok
t/01-ColourNames.......ok
t/02-X.................ok
t/03-HTML..............ok
t/04-Windows...........ok
t/05-Netscape..........ok
t/06-obj...............ok
t/07-file..............ok
t/08-filehandle........ok
Test Summary Report
-------------------
t/00-pod-coverage.t (Wstat: 65280 Tests: 0 Failed: 0)
Non-zero exit status: 255
Parse errors: Bad plan. You planned 6 tests but ran 0.
Files=12, Tests=178, 1 wallclock secs ( 0.04 usr 0.01 sys + 0.46 cusr
0.05 csys = 0.56 CPU)
Result: FAIL
Failed 1/12 test programs. 0/178 subtests failed.
make: *** [test_dynamic] Error 255
RRWO/Graphics-ColorNames-1.06.tar.gz
/usr/bin/make test -- NOT OK
//hint// to see the cpan-testers results for installing this module,
//try:
reports RRWO/Graphics-ColorNames-1.06.tar.gz
Running make install
make test had returned bad status, won't install without force
Failed during this command:
RRWO/Graphics-ColorNames-1.06.tar.gz : make_test NO
Subject: | 00-pod-coverage.t.diff |
--- /tmp/00-pod-coverage.t 2007-12-13 15:04:39.953499641 -0800
+++ t/00-pod-coverage.t 2007-12-13 15:14:09.366632098 -0800
@@ -1,11 +1,16 @@
#!/usr/bin/perl
use strict;
-use Test::More tests => 6;
+use Test::More;
eval "use Pod::Coverage";
+if ($@) {
+ plan skip_all => "Pod::Coverage required";
+}
+else {
+ plan tests => 6;
+}
-plan skip_all => "Pod::Coverage required" if $@;
ok( Pod::Coverage->new( package => 'Graphics::ColorNames' ) );
ok( Pod::Coverage->new( package => 'Graphics::ColourNames' ) );