# from David Golden # on Monday 30 July 2007 01:06 pm: ># pod-coverage.t >use Test::More; >plan skip_all => "Skipping author tests" if not $ENV{AUTHOR_TESTING}; > >my $min_tpc = 1.08; >eval "use Test::Pod::Coverage $min_tpc"; >plan skip_all => "Test::Pod::Coverage $min_tpc required for testing
No. If AUTHOR_TESTING, fail miserably unless the pod and coverage both 1. gets tested and 2. passes. That means the Test::Pod::* module in question must load. While you're at it, put it somewhere "out of the way" (as Aristotle said), like "at/" and forget this environment variable sillyness. at/pod-coverage.t use Test::More; use Test::Pod::Coverage 1.08; all_pod_coverage_ok(); at/pod.t use Test::More; use Test::Pod 1.14; all_pod_files_ok(); Who knows when you'll run into a box in the publishing industry which just happens to be setup for AUTHOR_TESTING some other system. Or, simply the hardcore CPAN author who put it in their .bashrc and forgot about it until some broken pod appeared in the middle of a big dependency stack. Environment variables are as global as they get. I think the "skipped more often than run" use-case should also imply something. I keep my winter clothes in the back of the closet during the summer and all-that. --Eric -- "It is impossible to make anything foolproof because fools are so ingenious." --Murphy's Second Corollary --------------------------------------------------- http://scratchcomputing.com ---------------------------------------------------