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");
}
}
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" );
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;