
steve at fisharerojo
Nov 13, 2006, 7:31 PM
Views: 226
Permalink
|
|
Tesing Pod::Coverage and bleadperl
|
|
One thing I noticed with testing modules with bleadperl was that some modules were failing Pod coverage tests (File::Slurp for example). The problem seems to be caused by the changes to constant subroutines in bleadperl. For example, a simple module like... package Failing::Pod::Coverage; use warnings; use strict; use POSIX qw( :fcntl_h ) ; use Fcntl qw( :DEFAULT ) ; use Symbol; 1; __END__ =head1 NAME Failing::Pod::Coverage - test failing Pod coverage fails like... t/pod-coverage.... # Failed test 'Pod coverage on Failing::Pod::Coverage' # at /tmp/bleadperl/lib/site_perl/5.9.5/Test/Pod/Coverage.pm line 126. # Coverage for Failing::Pod::Coverage is 0.0%, with 22 naked subroutines: # FD_CLOEXEC # F_DUPFD # F_GETFD # F_GETFL # F_GETLK # F_RDLCK # F_SETFD # F_SETFL # F_SETLK # F_SETLKW # F_UNLCK # F_WRLCK # O_ACCMODE # O_APPEND # O_CREAT # O_EXCL # O_NOCTTY # O_NONBLOCK # O_RDONLY # O_RDWR # O_TRUNC # O_WRONLY # Looks like you failed 1 test of 1. t/pod-coverage....dubious Test returned status 1 (wstat 256, 0x100) DIED. FAILED test 1 Failed 1/1 tests, 0.00% okay So what I'm wondering is whether there is a way to detect constant subs, especially imported ones to prevent failing tests like what's above. Steve Peters steve[at]fisharerojo.org
|