This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [perl-5.8.7] Perl regression tests fail when lib directory is present


Michael G Schwern wrote:

On Mon, Jul 18, 2005 at 12:27:31AM +0200, Gerrit P. Haase wrote:

perl -MTest::Harness -Iblib/lib -Iblib/arch -wle '$Test::Harness::Debug = 1; $Test::Harness::Verbose = 1; runtests @ARGV' t/*.t
The lines we're looking for are "# PERL5LIB=..." from THS->analyze_file()
telling us how TH is setting @INC.

t/test0....# Running: /usr/bin/perl -w t/test0.t # PERL5LIB=blib/lib:blib/arch 1..1 # Running under perl version 5.008007 for cygwin # Current time local: Mon Jul 18 00:14:08 2005 # Current time GMT: Sun Jul 17 22:14:08 2005 # Using Test.pm version 1.25 ok 1 ok t/test1....# Running: /usr/bin/perl -w t/test1.t # PERL5LIB=


At this point I'd suspect there's something broken about %ENV.  Try replacing
this in THS->analyze_file:

    local $ENV{PERL5LIB} = $self->_INC2PERL5LIB;
    if ( $Test::Harness::Debug ) {
        local $^W=0; # ignore undef warnings
        print "# PERL5LIB=$ENV{PERL5LIB}\n";
    }

with this:

    my $libs = $self->_INC2PERL5LIB;
    local $ENV{PERL5LIB} = $libs;
    if ( $Test::Harness::Debug ) {
        local $^W=0; # ignore undef warnings
        print STDERR "# PERL5LIB=$ENV{PERL5LIB}\n";
	print STDERR "# libs=$libs\n";
    }

to determine if _INC2PERL5LIB() is acting properly.


$ perl -MTest::Harness -Iblib/lib -Iblib/arch -wle '$Test::Harness::Debug = 1; $Test::Harness::Verbose = 1; runtests @ARGV' t/*.t
t/test0....# Running: /usr/bin/perl -w t/test0.t
# PERL5LIB=blib/lib:blib/arch
# libs=blib/lib:blib/arch
1..1
# Running under perl version 5.008007 for cygwin
# Current time local: Mon Jul 18 00:59:23 2005
# Current time GMT: Sun Jul 17 22:59:23 2005
# Using Test.pm version 1.25
ok 1
ok
t/test1....# Running: /usr/bin/perl -w t/test1.t
# PERL5LIB=
# libs=
Can't locate TestModule.pm in @INC (@INC contains: /usr/lib/perl5/5.8/cygwin /usr/lib/perl5/5.8 /usr/lib/perl5/site_perl/5.8/cygwin /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/vendor_perl/5.8/cygwin /usr/lib/perl5/vendor_perl/5.8 /usr/lib/perl5/vendor_perl/5.8 .) at t/test1.t line 2.
BEGIN failed--compilation aborted at t/test1.t line 2.
dubious
Test returned status 2 (wstat 512, 0x200)
t/test2....# Running: /usr/bin/perl -w t/test2.t
# PERL5LIB=blib/lib:blib/arch
# libs=blib/lib:blib/arch
1..1
# Running under perl version 5.008007 for cygwin
# Current time local: Mon Jul 18 00:59:24 2005
# Current time GMT: Sun Jul 17 22:59:24 2005
# Using Test.pm version 1.25
ok 1
ok
t/test3....# Running: /usr/bin/perl -w t/test3.t
# PERL5LIB=
# libs=
Can't locate TestModule.pm in @INC (@INC contains: /usr/lib/perl5/5.8/cygwin /usr/lib/perl5/5.8 /usr/lib/perl5/site_perl/5.8/cygwin /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/vendor_perl/5.8/cygwin /usr/lib/perl5/vendor_perl/5.8 /usr/lib/perl5/vendor_perl/5.8 .) at t/test3.t line 2.
BEGIN failed--compilation aborted at t/test3.t line 2.
dubious
Test returned status 2 (wstat 512, 0x200)
t/test4....# Running: /usr/bin/perl -w t/test4.t
# PERL5LIB=blib/lib:blib/arch
# libs=blib/lib:blib/arch
1..1
# Running under perl version 5.008007 for cygwin
# Current time local: Mon Jul 18 00:59:25 2005
# Current time GMT: Sun Jul 17 22:59:25 2005
# Using Test.pm version 1.25
ok 1
ok
t/test5....# Running: /usr/bin/perl -w t/test5.t
# PERL5LIB=
# libs=
Can't locate TestModule.pm in @INC (@INC contains: /usr/lib/perl5/5.8/cygwin /usr/lib/perl5/5.8 /usr/lib/perl5/site_perl/5.8/cygwin /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/vendor_perl/5.8/cygwin /usr/lib/perl5/vendor_perl/5.8 /usr/lib/perl5/vendor_perl/5.8 .) at t/test5.t line 2.
BEGIN failed--compilation aborted at t/test5.t line 2.
dubious
Test returned status 2 (wstat 512, 0x200)
Failed Test Stat Wstat Total Fail Failed List of Failed
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
t/test1.t 2 512 ?? ?? % ??
t/test3.t 2 512 ?? ?? % ??
t/test5.t 2 512 ?? ?? % ??
Failed 3/6 test scripts, 50.00% okay. 0/3 subtests failed, 100.00% okay.



-- =^..^=

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]