Skip Menu |

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

Report information
The Basics
Id: 68612
Status: new
Priority: 0/
Queue: Apache-Test

People
Owner: Nobody in particular
Requestors: mschout [...] gkg.net
Cc:
AdminCc:

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



Subject: Apache::Test 1.36 broken with mod_perl version 1.x
Date: Thu, 02 Jun 2011 13:47:10 -0500
To: bug-apache-test [...] rt.cpan.org, PHRED [...] cpan.org
From: Michael Schout <mschout [...] gkg.net>
Hi. It seems that version 1.36 of Apache::Test does not work with mod_perl 1.x. The following tests fail in Apache::Test 1.36 (I tried against apache 1.3.33/mod_perl 1.31): Failed Test Stat Wstat Total Fail List of Failed ------------------------------------------------------------------------------- t/more/01testpm.t 255 65280 ?? ?? ?? t/more/02testmore.t 255 65280 ?? ?? ?? t/more/03testpm.t 255 65280 ?? ?? ?? t/more/04testmore.t 255 65280 ?? ?? ?? 2 tests skipped. Failed 4/16 test scripts. 0/93 subtests failed. Files=16, Tests=93, 8 wallclock secs ( 4.38 cusr + 0.71 csys = 5.09 CPU) Failed 4/16 test programs. 0/93 subtests failed. A quick git bisect points to this commit as the problem: svn rev 1062529: Show quoted text
> Deprecate t/TEST -times=X in favor of t/SMOKE -times=X. Changes to > TAP::Harness have removed the ability to re-use test object attributes. > > Also generate t/SMOKE on build now, instead of requiring the user to build it. > > Remove iteration variable for SMOKE, using only -times as the controller. > > Thanks to Jim Jagielski for the spot on the -times=X issue on t/TEST.
Thats a fairly large commit, but I narrowed it down further to just the use of Apache::TestSmoke in lib/Apache/TestMM.pm If I reverse only this part: Show quoted text
> @@ -20,8 +20,9 @@ use warnings FATAL => 'all'; > > use Config; > use Apache::TestConfig (); > use Apache::TestTrace; > +use Apache::TestSmoke; > > sub import { > my $class = shift; > > @@ -138,8 +139,9 @@ sub generate_script { > close $in; > > info "generating script $file"; > Apache::Test::basic_config()->write_perlscript($file, $body); > + Apache::TestSmoke->generate_script; > } > > sub filter_args { > my($argv, $vars) =
------ Then the tests pass again in v1.x (against Apache::Test trunk HEAD) The t/logs/error_log seems to suggest that FindBin (used in TestSmoke.pm) is the problem: Show quoted text
> [Thu Jun 2 13:43:29 2011] [error] Cannot find current script '/dev/null' at /home/mschout/perl5/perlbrew/perls/perl-5.8.9/lib/5.8.9/FindBin.pm line 206\nBEGIN failed--compilation aborted at /home/mschout/perl5/perlbrew/perls/perl-5.8.9/lib/5.8.9/FindBin.pm line 206.\nCompilation failed in require at /home/mschout/dev/apache-test/t/../lib/Apache/TestSmoke.pm line 31.\nBEGIN failed--compilation aborted at /home/mschout/dev/apache-test/t/../lib/Apache/TestSmoke.pm line 31.\nCompilation failed in require at /home/mschout/dev/apache-test/t/../lib/Apache/TestMM.pm line 24.\nBEGIN failed--compilation aborted at /home/mschout/dev/apache-test/t/../lib/Apache/TestMM.pm line 24.\nCompilation failed in require at /home/mschout/dev/apache-test/t/../lib/Apache/TestRun.pm line 22.\nBEGIN failed--compilation aborted at /home/mschout/dev/apache-test/t/../lib/Apache/TestRun.pm line 22.\nCompilation failed in require at /home/mschout/dev/apache-test/t/../lib/Apache/TestServer.pm line 26.\nBE
GIN failed--compilation aborted at /home/mschout/dev/apache-test/t/../lib/Apache/TestServer.pm line 26.\nCompilation failed in require at /home/mschout/dev/apache-test/t/../lib/Apache/TestConfig.pm line 55.\nBEGIN failed--compilation aborted at /home/mschout/dev/apache-test/t/../lib/Apache/TestConfig.pm line 55.\nCompilation failed in require at /home/mschout/dev/apache-test/t/../lib/Apache/Test.pm line 23.\nBEGIN failed--compilation aborted at /home/mschout/dev/apache-test/t/../lib/Apache/Test.pm line 23.\nCompilation failed in require at /home/mschout/dev/apache-test/t/response/TestMore/testpm.pm line 6.\nBEGIN failed--compilation aborted at /home/mschout/dev/apache-test/t/response/TestMore/testpm.pm line 6.\nCompilation failed in require at (eval 14) line 3.\n Show quoted text
> [Thu Jun 2 13:43:29 2011] [error] Undefined subroutine &TestMore::testpm::handler called.\n > [Thu Jun 2 13:43:30 2011] [error] plan() doesn't understand Apache=SCALAR(0x111a470) tests at /home/mschout/dev/apache-test/t/response/TestMore/testmorepm.pm line 11.\n > [Thu Jun 2 13:43:30 2011] [error] Undefined subroutine &TestMore::testpm::handler called.\n > [Thu Jun 2 13:43:31 2011] [error] plan() doesn't understand Apache=SCALAR(0x111a4a0) tests at /home/mschout/dev/apache-test/t/response/TestMore/testmorepm.pm line 11.\n > [Thu Jun 2 13:43:32 2011] [info] removed PID file /home/mschout/dev/apache-test/t/logs/httpd.pid (pid=13949) > [Thu Jun 2 13:43:32 2011] [notice] caught SIGTERM, shutting down
So for whatever reason, FindBin isn't working in mod_perl 1.x.. not sure what the best solution to this is. Regards, Michael Schout