Subject: | t/17-switch.t fails on perl <5.18 |
[markgardner:~/.cpanm … Dist-Zilla-Plugin-Test-Compile-2.055] $ perl Makefile.PL verbose
Checking if your kit is complete...
Looks good
ABSTRACT => q[Common tests to check syntax of your modules, using only core modules]
AUTHOR => [q[J�r�me Quelin <jquelin@gmail.com>, Karen Etheridge <ether@cpan.org>]]
BUILD_REQUIRES => { }
CONFIGURE_REQUIRES => { Module::Build::Tiny=>q[0.034] }
DISTNAME => q[Dist-Zilla-Plugin-Test-Compile]
LICENSE => q[perl]
MIN_PERL_VERSION => q[5.008]
NAME => q[Dist::Zilla::Plugin::Test::Compile]
PL_FILES => { }
PREREQ_PM => { Data::Section=>q[0.004], Dist::Zilla=>q[4.300039], Dist::Zilla::Dist::Builder=>q[0], Dist::Zilla::File::InMemory=>q[0], Dist::Zilla::Role::FileFinderUser=>q[0], Dist::Zilla::Role::FileGatherer=>q[0], Dist::Zilla::Role::FileMunger=>q[0], Dist::Zilla::Role::PrereqSource=>q[0], Dist::Zilla::Role::TextTemplate=>q[0], Moose=>q[0], Moose::Util::TypeConstraints=>q[0], Path::Tiny=>q[0], Sub::Exporter::ForMethods=>q[0], namespace::autoclean=>q[0], strict=>q[0], warnings=>q[0] }
TEST_REQUIRES => { CPAN::Meta::Check=>q[0.011], CPAN::Meta::Requirements=>q[0], File::Spec=>q[0], File::pushd=>q[0], IO::Handle=>q[0], IPC::Open3=>q[0], Module::CoreList=>q[2.77], Module::Metadata=>q[0], Perl::PrereqScanner=>q[1.016], Test::DZil=>q[0], Test::Deep=>q[0], Test::MinimumVersion=>q[0], Test::More=>q[0.94], Test::Warnings=>q[0.009], blib=>q[1.01], if=>q[0], utf8=>q[0], version=>q[0] }
VERSION => q[2.055]
test => { TESTS=>q[t/*.t] }
Using PERL=/Users/markgardner/.plenv/versions/5.16.3/bin/perl5.16.3
Generating a Unix-style Makefile
Writing Makefile for Dist::Zilla::Plugin::Test::Compile
Writing MYMETA.yml and MYMETA.json
[markgardner:~/.cpanm … Dist-Zilla-Plugin-Test-Compile-2.055] $ make
cp lib/Dist/Zilla/Plugin/Test/Compile.pm blib/lib/Dist/Zilla/Plugin/Test/Compile.pm
Manifying 1 pod document
[markgardner:~/.cpanm … Dist-Zilla-Plugin-Test-Compile-2.055] $ TEST_VERBOSE=1 make test
PERL_DL_NONLAZY=1 "/Users/markgardner/.plenv/versions/5.16.3/bin/perl5.16.3" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00-compile.t ................... ok
t/00-report-prereqs.t ............ #
# Versions for all modules listed in MYMETA.json (including optional ones):
#
# === Configure Requires ===
#
# Module Want Have
# ------------------- ----- -----
# Module::Build::Tiny 0.034 0.039
#
# === Build Requires ===
#
# Module Want Have
# ------------------- ---- ----
# ExtUtils::MakeMaker any 7.24
#
# === Test Requires ===
#
# Module Want Have
# ------------------------ ----- ----------
# CPAN::Meta::Check 0.011 0.013
# CPAN::Meta::Requirements any 2.131
# File::Spec any 3.39_02
# File::pushd any 1.014
# IO::Handle any 1.33
# IPC::Open3 any 1.12
# Module::CoreList 2.77 5.20161020
# Module::Metadata any 1.000033
# Perl::PrereqScanner 1.016 1.023
# Test::DZil any 6.008
# Test::Deep any 1.123
# Test::MinimumVersion any 0.101082
# Test::More 0.94 1.302062
# Test::Warnings 0.009 0.026
# blib 1.01 1.06
# if any 0.0602
# utf8 any 1.09
# version any 0.99
#
# === Test Recommends ===
#
# Module Want Have
# ---------- -------- --------
# CPAN::Meta 2.120900 2.143240
#
# === Runtime Requires ===
#
# Module Want Have
# --------------------------------- -------- --------
# Data::Section 0.004 0.200006
# Dist::Zilla 4.300039 6.008
# Dist::Zilla::Dist::Builder any 6.008
# Dist::Zilla::File::InMemory any 6.008
# Dist::Zilla::Role::FileFinderUser any 6.008
# Dist::Zilla::Role::FileGatherer any 6.008
# Dist::Zilla::Role::FileMunger any 6.008
# Dist::Zilla::Role::PrereqSource any 6.008
# Dist::Zilla::Role::TextTemplate any 6.008
# Moose any 2.1806
# Moose::Util::TypeConstraints any 2.1806
# Path::Tiny any 0.098
# Sub::Exporter::ForMethods any 0.100052
# namespace::autoclean any 0.28
# strict any 1.07
# warnings any 1.13
#
# === Other Modules ===
#
# Module Have
# --------------------- --------
# CPAN::Meta::Validator 2.143240
# Dist::CheckConflicts 0.11
# JSON::PP 2.27400
# Pod::Coverage missing
# Sub::Name 0.21
# YAML missing
# autodie 2.10
#
t/00-report-prereqs.t ............ ok
t/01-basic.t ..................... ok
t/02-warnings.t .................. ok
t/03-taint.t ..................... ok
t/04-bash.t ...................... ok
t/05-prereqs.t ................... ok
t/06-filename.t .................. ok
t/07-prereqs-phase.t ............. ok
t/08-xt_mode.t ................... ok
t/09-extra-files.t ............... ok
t/10-shebang-w.t ................. ok
t/11-shebang-C.t ................. ok
t/12-shebang-comment.t ........... ok
t/13-shebang-dashes.t ............ ok
t/14-extratests.t ................ ok
t/15-needs-display.t ............. ok
t/16-filename-fail-on-warning.t .. ok
t/17-switch.t ....................
# Failed test 'got expected warnings from compiling a module with a deprecation warning'
# at t/17-switch.t line 104.
# Compared array length of $data
# got : array with 0 element(s)
# expect : array with 1 element(s)
# got warning(s): []
# got log messages: [
# '[DZ] beginning to build DZT-Sample',
# '[GatherDir] considering .',
# '[GatherDir] considering dist.ini',
# '[GatherDir] considering bin',
# '[GatherDir] considering bin/foobar',
# '[GatherDir] considering lib',
# '[GatherDir] considering lib/Foo.pm',
# '[GatherDir] adding file dist.ini',
# '[GatherDir] adding file bin/foobar',
# '[GatherDir] adding file lib/Foo.pm',
# '[MakeMaker] adding file Makefile.PL',
# '[Test::Compile] adding file t/00-compile.t',
# '[Test::Compile] adding module Foo.pm',
# '[Test::Compile] adding script bin/foobar',
# '[MakeMaker] updating contents of Makefile.PL in memory',
# '[DZ] writing DZT-Sample in /Users/markgardner/.cpanm/work/1477405933.52512/Dist-Zilla-Plugin-Test-Compile-2.055/tmp/RRxx7Iimin/build',
# '[MakeMaker::Runner] running /Users/markgardner/.plenv/versions/5.16.3/bin/perl5.16.3 Makefile.PL',
# '[MakeMaker::Runner] running make'
# ]
# Looks like you failed 1 test of 8.
t/17-switch.t .................... 1/?
# Failed test 'no switches'
# at t/17-switch.t line 112.
t/17-switch.t .................... 2/? # Looks like you failed 1 test of 2.
t/17-switch.t .................... Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/2 subtests
t/zzz-check-breaks.t ............. ok
Test Summary Report
-------------------
t/17-switch.t (Wstat: 256 Tests: 2 Failed: 1)
Failed test: 1
Non-zero exit status: 1
Files=20, Tests=101, 23 wallclock secs ( 0.09 usr 0.04 sys + 19.88 cusr 2.64 csys = 22.65 CPU)
Result: FAIL
Failed 1/20 test programs. 1/101 subtests failed.
make: *** [test_dynamic] Error 255
[markgardner:~/.cpanm … Dist-Zilla-Plugin-Test-Compile-2.055] 23s 2 $ prove -vl t/17-switch.t
t/17-switch.t ..
# Subtest: no switches
ok 1 - test created
ok 2 - no trailing whitespace in generated test
ok 3 - test checks Foo.pm
ok 4 - test checks bin/foobar
ok 5 - dumped configs are good
# Subtest: run the generated test
Generating a Unix-style Makefile
Writing Makefile for DZT::Sample
Writing MYMETA.yml and MYMETA.json
cp lib/Foo.pm blib/lib/Foo.pm
cp bin/foobar blib/script/foobar
"/Users/markgardner/.plenv/versions/5.16.3/bin/perl5.16.3" -MExtUtils::MY -e 'MY->fixin(shift)' -- blib/script/foobar
1..2
ok 1 - Foo.pm loaded ok
ok 2 - bin/foobar compiled ok
# ran tests successfully
ok 6 - run the generated test
ok 7 - correct number of files were tested
not ok 8 - got expected warnings from compiling a module with a deprecation warning
# Failed test 'got expected warnings from compiling a module with a deprecation warning'
# at t/17-switch.t line 104.
# Compared array length of $data
# got : array with 0 element(s)
# expect : array with 1 element(s)
# got warning(s): []
# got log messages: [
# '[DZ] beginning to build DZT-Sample',
# '[GatherDir] considering .',
# '[GatherDir] considering dist.ini',
# '[GatherDir] considering bin',
# '[GatherDir] considering bin/foobar',
# '[GatherDir] considering lib',
# '[GatherDir] considering lib/Foo.pm',
# '[GatherDir] adding file dist.ini',
# '[GatherDir] adding file bin/foobar',
# '[GatherDir] adding file lib/Foo.pm',
# '[MakeMaker] adding file Makefile.PL',
# '[Test::Compile] adding file t/00-compile.t',
# '[Test::Compile] adding module Foo.pm',
# '[Test::Compile] adding script bin/foobar',
# '[MakeMaker] updating contents of Makefile.PL in memory',
# '[DZ] writing DZT-Sample in /Users/markgardner/.cpanm/work/1477405933.52512/Dist-Zilla-Plugin-Test-Compile-2.055/tmp/8tW0DSRcac/build',
# '[MakeMaker::Runner] running /Users/markgardner/.plenv/versions/5.16.3/bin/perl5.16.3 Makefile.PL',
# '[MakeMaker::Runner] running make'
# ]
1..8
not ok 1 - no switches
# Subtest: deprecation warnings disabled
# Looks like you failed 1 test of 8.
# Failed test 'no switches'
# at t/17-switch.t line 112.
ok 1 - test created
ok 2 - no trailing whitespace in generated test
ok 3 - test checks Foo.pm
ok 4 - test checks bin/foobar
ok 5 - dumped configs are good
# Subtest: run the generated test
Generating a Unix-style Makefile
Writing Makefile for DZT::Sample
Writing MYMETA.yml and MYMETA.json
cp lib/Foo.pm blib/lib/Foo.pm
cp bin/foobar blib/script/foobar
"/Users/markgardner/.plenv/versions/5.16.3/bin/perl5.16.3" -MExtUtils::MY -e 'MY->fixin(shift)' -- blib/script/foobar
1..2
ok 1 - Foo.pm loaded ok
ok 2 - bin/foobar compiled ok
# ran tests successfully
ok 6 - run the generated test
ok 7 - correct number of files were tested
ok 8 - got expected warnings from compiling a module with a deprecation warning
1..8
ok 2 - deprecation warnings disabled
1..2
# Looks like you failed 1 test of 2.
Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/2 subtests
Test Summary Report
-------------------
t/17-switch.t (Wstat: 256 Tests: 2 Failed: 1)
Failed test: 1
Non-zero exit status: 1
Files=1, Tests=2, 2 wallclock secs ( 0.02 usr 0.01 sys + 1.61 cusr 0.31 csys = 1.95 CPU)
Result: FAIL