Subject: | Tests fail with Perl 5 blead due to non-dot-by-default-in-@INC |
In Perl 5.26.0, '.' will no longer be found by default in @INC. When built against a recent Perl 5 blead which incorporates this new feature, most of Text-CSV's tests fail. Here is an excerpt from the output of trying to install Text-CSV against blead using 'cpanm':
#####
Searching Text::CSV () on cpanmetadb ...
--> Working on Text::CSV
Fetching http://www.cpan.org/authors/id/I/IS/ISHIGAKI/Text-CSV-1.91.tar.gz
-> OK
[snip]
PERL_DL_NONLAZY=1 "/home/jkeenan/testing/blead/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
# PERL_TEXT_CSV: undef
t/00_pod.t ............... ok
t/10_base.t .............. ok
t/12_acc.t ............... ok
t/15_flags.t ............. ok
Can't locate t/util.pl in @INC (@INC contains: /home/jkeenan/.cpanm/work/1490881305.4413/Text-CSV-1.91/blib/lib /home/jkeenan/.cpanm/work/1490881305.4413/Text-CSV-1.91/blib/arch /home/jkeenan/testing/blead/lib/perl5/site_perl/5.25.11/x86_64-linux /home/jkeenan/testing/blead/lib/perl5/site_perl/5.25.11 /home/jkeenan/testing/blead/lib/perl5/5.25.11/x86_64-linux /home/jkeenan/testing/blead/lib/perl5/5.25.11) at t/20_file.t line 12.
BEGIN failed--compilation aborted at t/20_file.t line 13.
# Looks like your test exited with 2 just after 1.
t/20_file.t ..............
Dubious, test returned 2 (wstat 512, 0x200)
Failed 104/105 subtests
t/21_lexicalio.t .........
Dubious, test returned 2 (wstat 512, 0x200)
Failed 104/105 subtests
Can't locate t/util.pl in @INC (@INC contains: /home/jkeenan/.cpanm/work/1490881305.4413/Text-CSV-1.91/blib/lib /home/jkeenan/.cpanm/work/1490881305.4413/Text-CSV-1.91/blib/arch /home/jkeenan/testing/blead/lib/perl5/site_perl/5.25.11/x86_64-linux /home/jkeenan/testing/blead/lib/perl5/site_perl/5.25.11 /home/jkeenan/testing/blead/lib/perl5/5.25.11/x86_64-linux /home/jkeenan/testing/blead/lib/perl5/5.25.11) at t/22_scalario.t line 26.
BEGIN failed--compilation aborted at t/22_scalario.t line 27.
# Looks like your test exited with 2 just after 1.
[snip]
Dubious, test returned 2 (wstat 512, 0x200)
Failed 7/8 subtests
Test Summary Report
-------------------
t/20_file.t (Wstat: 512 Tests: 1 Failed: 0)
Non-zero exit status: 2
Parse errors: Bad plan. You planned 105 tests but ran 1.
t/21_lexicalio.t (Wstat: 512 Tests: 1 Failed: 0)
Non-zero exit status: 2
Parse errors: Bad plan. You planned 105 tests but ran 1.
t/22_scalario.t (Wstat: 512 Tests: 1 Failed: 0)
Non-zero exit status: 2
Parse errors: Bad plan. You planned 132 tests but ran 1.
[snip]
Files=31, Tests=919, 2 wallclock secs ( 0.11 usr 0.03 sys + 1.31 cusr 0.10 csys = 1.55 CPU)
Result: FAIL
Failed 18/31 test programs. 0/919 subtests failed.
Makefile:857: recipe for target 'test_dynamic' failed
make: *** [test_dynamic] Error 2
#####
I will submit a pull request.
Thank you very much.
Jim Keenan