From: Jarkko Hietaniemi Date: Sat, 1 Jun 2002 04:05:35 +0000 (+0000) Subject: Make the changes MacOS-specific. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=66bb7cd37233fc25c787d5948121ba0478ea860a;p=p5sagit%2Fp5-mst-13.2.git Make the changes MacOS-specific. p4raw-id: //depot/perl@16954 --- diff --git a/lib/Test/Harness/t/callback.t b/lib/Test/Harness/t/callback.t index 63aaa22..6a57fd5 100644 --- a/lib/Test/Harness/t/callback.t +++ b/lib/Test/Harness/t/callback.t @@ -54,7 +54,10 @@ $strap->{callback} = sub { while( my($test, $expect) = each %samples ) { local @out = (); - $strap->analyze_file(catfile($SAMPLE_TESTS, $test)); + + $strap->analyze_file($^O eq 'macos' ? + catfile($SAMPLE_TESTS, $test) : + "$SAMPLE_TESTS/$test"); is_deeply(\@out, $expect, "$test callback"); } diff --git a/lib/Test/Harness/t/strap-analyze.t b/lib/Test/Harness/t/strap-analyze.t index 96b549a..59e4a5c 100644 --- a/lib/Test/Harness/t/strap-analyze.t +++ b/lib/Test/Harness/t/strap-analyze.t @@ -463,7 +463,9 @@ while( my($test, $expect) = each %samples ) { } my $strap = Test::Harness::Straps->new; - my %results = $strap->analyze_file(catfile($SAMPLE_TESTS, $test)); + my %results = $strap->analyze_file($^O eq 'macos' ? + catfile($SAMPLE_TESTS, $test) : + "$SAMPLE_TESTS/$test"); is_deeply($results{details}, $expect->{details}, "$test details" ); diff --git a/lib/Test/Harness/t/test-harness.t b/lib/Test/Harness/t/test-harness.t index f75f379..be95a54 100644 --- a/lib/Test/Harness/t/test-harness.t +++ b/lib/Test/Harness/t/test-harness.t @@ -431,7 +431,9 @@ while (my($test, $expect) = each %samples) { select NULL; # _run_all_tests() isn't as quiet as it should be. local $SIG{__WARN__} = sub { $warning .= join '', @_; }; ($totals, $failed) = - Test::Harness::_run_all_tests(catfile($SAMPLE_TESTS, $test)); + Test::Harness::_run_all_tests($^O eq 'macos' ? + catfile($SAMPLE_TESTS, $test) : + "$SAMPLE_TESTS/$test"); }; select STDOUT;