Skip Menu |
 

This queue is for tickets about the Test-Harness CPAN distribution.

Report information
The Basics
Id: 37124
Status: resolved
Priority: 0/
Queue: Test-Harness

People
Owner: Nobody in particular
Requestors: doughera [...] lafayette.edu
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



CC: Perl Porters <perl5-porters [...] perl.org>, bug-test-harness [...] rt.cpan.org
Subject: Re: utils/prove loses @INC settings
Date: Thu, 26 Jun 2008 09:16:40 -0400 (EDT)
To: Eric Wilhelm <scratchcomputing [...] gmail.com>
From: Andy Dougherty <doughera [...] lafayette.edu>
Download (untitled) / with headers
text/plain 1.7k
On Wed, 25 Jun 2008, Eric Wilhelm wrote: Show quoted text
> # from Andy Dougherty > # on Wednesday 25 June 2008 14:07: >
> >In 5.10.x, it is apparently necessary to do > >    > >    ./perl -Ilib utils/prove -Ilib try.t > > > >That's right:  -Ilib must be specified twice.  Without the first one, > >perl complains 'Can't locate strict.pm'.  I don't know how, why, or > > when utils/prove loses track of the ./lib directory.
> > It does not "lose track of" the @INC from the parent process. > > TAP::Harness *does* introduce a separation between "options passed to > the perl which runs prove" and "options passed to the perl which runs > tests" -- this distinction is by design.
Fair enough. It is an incompatible change from the 5.8.8 behavior, though, so how about a documentation patch something like this? It would have been enough to let me know what was going on and that it was deliberate. diff -r -u perl-current/lib/Test/Harness/bin/prove perl-andy/lib/Test/Harness/bin/prove --- perl-current/lib/Test/Harness/bin/prove 2008-02-11 12:00:19.000000000 -0500 +++ perl-andy/lib/Test/Harness/bin/prove 2008-06-26 09:08:55.000000000 -0400 @@ -240,6 +240,15 @@ $ prove -b --state=hot --state=all,save +=head2 @INC + +prove introduces a separation between "options passed to the +perl which runs prove" and "options passed to the perl which runs tests" +-- this distinction is by design. Thus the perl which is running a +test starts with the default C<@INC>. Additional library directories +can be added either via the C<PERL5LIB> environment variable or via +the C<-Ilib> option to F<prove>. + =head2 Taint Mode Normally when a Perl program is run in taint mode the contents of the -- Andy Dougherty doughera@lafayette.edu
Patch applied as r1292.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.