Skip Menu |

This queue is for tickets about the Module-Build CPAN distribution.

Report information
The Basics
Id: 35585
Status: resolved
Priority: 0/
Queue: Module-Build

People
Owner: Nobody in particular
Requestors: gam3-cpan [...] gam3.net
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.2807
Fixed in: 0.2808



Subject: testpodcoverage does not test the correct code
Test::Pod::Coverage::all_pod_coverage_ok() uses @INC to load the modules that it is testing. Currently Module::Build does not set @INC to include the blib/lib directory, so only installed versions of the module being tested are checked. This patch set @INC so that all modules in 'libdoc_dirs()' be tested. This might be more of a bug in Test::Pod::Coverage as it look for modules in blib/ even in blib/ is not in @INC.
Subject: patch
Download patch
application/octet-stream 412b

Message body not shown because it is not plain text.

Subject: Re: [rt.cpan.org #35585] testpodcoverage does not test the correct code
Date: Fri, 02 May 2008 16:37:25 -0700
To: bug-Module-Build [...] rt.cpan.org
From: Michael G Schwern <schwern [...] pobox.com>
http://gam3.myopenid.com/ via RT wrote: Show quoted text
> Test::Pod::Coverage::all_pod_coverage_ok() uses @INC to load the modules > that it is testing. Currently Module::Build does not set @INC to > include the blib/lib directory, so only installed versions of the module > being tested are checked.
Are you sure? That would be a major bug if it were true. A simple test shows that blib/lib is in there. Here's one I tried with one of my simple Module::Build based distributions using MB 0.2808. $ pwd /Users/schwern/devel/Gravatar-URL $ cat t/inc.t #!/usr/bin/perl -w print STDERR map {"# $_\n"} grep /blib/, @INC; $ ./Build test t/inc........# /Users/schwern/devel/Gravatar-URL/blib/lib # /Users/schwern/devel/Gravatar-URL/blib/arch ... How did you determine that blib isn't showing up in @INC? -- 164. There is no such thing as a were-virgin. -- The 213 Things Skippy Is No Longer Allowed To Do In The U.S. Army http://skippyslist.com/list/
Subject: Re: [rt.cpan.org #35585] testpodcoverage does not test the correct code
Date: Fri, 2 May 2008 23:13:55 -0400
To: Michael G Schwern via RT <bug-Module-Build [...] rt.cpan.org>
From: "G. Allen Morris III" <gam3 [...] gam3.net>
On Fri, May 02, 2008 at 07:37:57PM -0400, Michael G Schwern via RT wrote: Show quoted text
... Show quoted text
> Are you sure? That would be a major bug if it were true.
I don't think that many people are using 'Build testpodcoverage'. Show quoted text
> A simple test shows that blib/lib is in there. Here's one I tried with one of > my simple Module::Build based distributions using MB 0.2808. > > $ pwd > /Users/schwern/devel/Gravatar-URL > > $ cat t/inc.t > #!/usr/bin/perl -w > > print STDERR map {"# $_\n"} grep /blib/, @INC; > > $ ./Build test > t/inc........# /Users/schwern/devel/Gravatar-URL/blib/lib > # /Users/schwern/devel/Gravatar-URL/blib/arch
'Build test' sets @INC correctly; it is 'Build testpodcoverage' that does not. Show quoted text
> ... > > How did you determine that blib isn't showing up in @INC?
I printed @INC in the source code for the testpodcoverage method.
Download signature.asc
application/pgp-signature 242b

Message body not shown because it is not plain text.

Subject: Re: [rt.cpan.org #35585] testpodcoverage does not test the correct code
Date: Fri, 2 May 2008 22:07:18 -0700
To: bug-Module-Build [...] rt.cpan.org
From: Eric Wilhelm <scratchcomputing [...] gmail.com>
# from gam3@gam3.net via RT # on Friday 02 May 2008: Show quoted text
>> How did you determine that blib isn't showing up in @INC?
> >I printed @INC in the source code for the testpodcoverage method.
The code and changelog says that I determined this was a pre-v1.09 Test::Pod::Coverage bug and there is a work-around is in M::B 0.2808. http://www.nntp.perl.org/group/perl.module.build/2007/01/msg469.html http://www.nntp.perl.org/group/perl.module.build/2007/04/msg605.html --Eric
Subject: Re: [rt.cpan.org #35585] testpodcoverage does not test the correct code
Date: Sat, 3 May 2008 06:57:09 -0400
To: Eric Wilhelm via RT <bug-Module-Build [...] rt.cpan.org>
From: "G. Allen Morris III" <gam3 [...] gam3.net>
Eric, On Sat, May 03, 2008 at 01:08:09AM -0400, Eric Wilhelm via RT wrote: Show quoted text
> > <URL: http://rt.cpan.org/Ticket/Display.html?id=35585 > > > The code and changelog says that I determined this was a pre-v1.09 > Test::Pod::Coverage bug and there is a work-around is in M::B 0.2808.
Thank you for the information. It still seems to me that Module-Build should be telling Test::Pod::Coverage what to test, and not just use the defaults. Allen Show quoted text
Download signature.asc
application/pgp-signature 242b

Message body not shown because it is not plain text.

Subject: Re: [rt.cpan.org #35585] testpodcoverage does not test the correct code
Date: Sat, 03 May 2008 23:58:56 -0700
To: bug-Module-Build [...] rt.cpan.org
From: Michael G Schwern <schwern [...] pobox.com>
gam3@gam3.net via RT wrote: Show quoted text
>> Are you sure? That would be a major bug if it were true.
> > I don't think that many people are using 'Build testpodcoverage'.
Sorry, I didn't realize this applied to the testpodcoverage target. -- 184. When operating a military vehicle I may *not* attempt something “I saw in a cartoon”. -- The 213 Things Skippy Is No Longer Allowed To Do In The U.S. Army http://skippyslist.com/list/
From: kwilliams [...] cpan.org
On Sat May 03 06:57:33 2008, gam3@gam3.net wrote: Show quoted text
> It still seems to me that Module-Build should be telling > Test::Pod::Coverage what to test, and not just use the defaults.
Not sure what you mean by that - as Eric said, blib/lib has been added at the front of @INC, which ought to solve the problem. -Ken
Subject: Re: [rt.cpan.org #35585] testpodcoverage does not test the correct code
Date: Wed, 7 May 2008 11:20:54 -0400
To: Ken Williams via RT <bug-Module-Build [...] rt.cpan.org>
From: "G. Allen Morris III" <gam3 [...] gam3.net>
On Wed, May 07, 2008 at 10:53:53AM -0400, Ken Williams via RT wrote: Show quoted text
> > Not sure what you mean by that - as Eric said, blib/lib has been added at the front of @INC, > which ought to solve the problem.
From the Test::Pod::Coverage man page all_modules( [@dirs] ) Returns a list of all modules in $dir and in directories below. If no directories are passed, it defaults to blib if blib exists, or lib if not. I guess I would say that 'Build testpodcoverage' should be the same as 'Build test --test_files t/podc.t' where t/podc.t looks like: use Test::More; eval "use Test::Pod::Coverage"; plan skip_all => "Test::Pod::Coverage required for testing pod coverage" if $@; all_pod_coverage_ok(); And as ACTION_test sets @INC, I think that ACTION_testpodcoverage should do the same.
Download signature.asc
application/pgp-signature 242b

Message body not shown because it is not plain text.

Subject: Re: [rt.cpan.org #35585] testpodcoverage does not test the correct code
Date: Wed, 7 May 2008 08:46:56 -0700
To: bug-Module-Build [...] rt.cpan.org
From: Eric Wilhelm <scratchcomputing [...] gmail.com>
# from gam3@gam3.net via RT # on Wednesday 07 May 2008: Show quoted text
>And as ACTION_test sets @INC, I think that ACTION_testpodcoverage > should do the same.
It does. And has been this way for over a year now. http://search.cpan.org/src/KWILLIAMS/Module-Build-0.2808/lib/Module/Build/Base.pm Am I missing something or are you running old code? --Eric
Subject: Re: [rt.cpan.org #35585] testpodcoverage does not test the correct code
Date: Wed, 7 May 2008 12:04:19 -0400
To: Eric Wilhelm via RT <bug-Module-Build [...] rt.cpan.org>
From: "G. Allen Morris III" <gam3 [...] gam3.net>
On Wed, May 07, 2008 at 11:47:12AM -0400, Eric Wilhelm via RT wrote: Show quoted text
> > Am I missing something or are you running old code?
As I stated in the original post; I am running 0.2807. And it does seem that it is fixed in 0.2808. Thanks Eric. Sorry for all the confusion. Show quoted text
> > --Eric
Download signature.asc
application/pgp-signature 242b

Message body not shown because it is not plain text.

On Fri May 02 12:30:18 2008, http://gam3.myopenid.com/ wrote: Show quoted text
> Test::Pod::Coverage::all_pod_coverage_ok() uses @INC to load the modules > that it is testing. Currently Module::Build does not set @INC to > include the blib/lib directory, so only installed versions of the module > being tested are checked. > > This patch set @INC so that all modules in 'libdoc_dirs()' be tested. > > This might be more of a bug in Test::Pod::Coverage as it look for > modules in blib/ even in blib/ is not in @INC.