Skip Menu |

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

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

People
Owner: Nobody in particular
Requestors:
Cc:
AdminCc:

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



Subject: Restore 5.4.5
I just tried out Test::Harness 2.52 against perl 5.4.5 today and discovered it refused to compile. I did this because Test::More claims to work as far back as 5.4.5 but it depends on Test::Harness >= 2.03. With some very minor modifications I've gotten TH working on 5.4.5. If the change was more invasive I'd consider dropping 5.4.5 entirely but as its a small fix I'd like to hang onto 5.4.5.
--- Test-Harness-2.52/Makefile.PL 2005-05-07 21:40:43.000000000 -0700 +++ Test-Harness-2.52.new/Makefile.PL 2005-07-03 15:26:27.000000000 -0700 @@ -1,4 +1,4 @@ -require 5.005_03; +require 5.004_05; use ExtUtils::MakeMaker; use ExtUtils::Command qw( touch rm_f ); --- Test-Harness-2.52/lib/Test/Harness/Point.pm 2005-03-02 19:42:43.000000000 -0800 +++ Test-Harness-2.52.new/lib/Test/Harness/Point.pm 2005-07-03 15:23:29.000000000 -0700 @@ -30,14 +30,14 @@ return $self; } -my $test_line_regex = qr/ +my $test_line_regex = ' ^ - (not\ )? # failure? - ok\b - (?:\s+(\d+))? # optional test number - \s* + (not\\ )? # failure? + ok\\b + (?:\\s+(\\d+))? # optional test number + \\s* (.*) # and the rest -/ox; +'; =head1 from_test_line( $line ) @@ -51,7 +51,7 @@ my $line = shift or return; # We pulverize the line down into pieces in three parts. - my ($not, $number, $extra) = ($line =~ $test_line_regex ) or return; + my ($not, $number, $extra) = ($line =~ /$test_line_regex/ox ) or return; my $point = $class->new; $point->set_number( $number ); --- Test-Harness-2.52/t/version.t 2005-03-02 14:03:36.000000000 -0800 +++ Test-Harness-2.52.new/t/version.t 2005-07-03 15:23:56.000000000 -0700 @@ -19,5 +19,5 @@ } my $ver = $ENV{HARNESS_VERSION} or die "HARNESS_VERSION not set"; -like( $ver, qr/^2.\d\d(_\d\d)?$/, "Version is proper format" ); +like( $ver, '/^2.\d\d(_\d\d)?$/', "Version is proper format" ); is( $ver, $Test::Harness::VERSION );
Next version of T::H (2.57_06) will have 5.4.5 support back again.