This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Test::Simple 0.81_02 has:
authorNicholas Clark <nick@ccl4.org>
Tue, 21 Oct 2008 06:49:53 +0000 (06:49 +0000)
committerNicholas Clark <nick@ccl4.org>
Tue, 21 Oct 2008 06:49:53 +0000 (06:49 +0000)
  Features Changed
     - Now preserves the tests' exit code if it exits abnormally,
       rather than setting it to 255.

$! is non-zero with PERLIO=stdio in some cases, so die would have set
the exit code to $! (typically 9). Now that would show through, so
ensure $! *is* zero to make sure that the exit code is 255.

p4raw-id: //depot/perl@34545

t/lib/Test/Simple/sample_tests/death.plx
t/lib/Test/Simple/sample_tests/death_with_handler.plx
t/lib/Test/Simple/sample_tests/last_minute_death.plx

index a7c0988..24f8cb2 100644 (file)
@@ -13,4 +13,5 @@ tie *STDERR, 'Dev::Null';
 ok(1);
 ok(1);
 ok(1);
+$! = 0;
 die "This is a test";