4 if( $ENV{PERL_CORE} ) {
6 @INC = ('../lib', 'lib');
15 require Test::Simple::Catch;
16 my($out, $err) = Test::Simple::Catch::caught();
17 local $ENV{HARNESS_ACTIVE} = 0;
20 # Can't use Test.pm, that's a 5.005 thing.
26 # Utility testing functions.
28 my($test, $name) = @_;
30 $ok .= "not " unless $test;
31 $ok .= "ok $test_num";
32 $ok .= " - $name" if defined $name;
42 Test::Simple->import(tests => 5);
46 ok( 2, 'passing still' );
47 ok( 3, 'still passing' );
53 My::Test::ok($$out eq <<OUT);
62 My::Test::ok($$err eq <<ERR);
63 # Failed test 'oh no!'
65 # Failed test 'damnit'
67 # Looks like you failed 2 tests of 5.
70 # Prevent Test::Simple from exiting with non zero