Commit | Line | Data |
845d7e37 |
1 | #!/usr/bin/perl |
2 | |
c0888b21 |
3 | BEGIN { |
4 | if( $ENV{PERL_CORE} ) { |
5 | chdir 't'; |
6 | @INC = '../lib'; |
7 | } |
8 | } |
9 | |
845d7e37 |
10 | use Test::Builder::Tester tests => 5; |
11 | use Test::More; |
12 | |
13 | # test_fail |
14 | |
68938d83 |
15 | test_fail(+1, 'one'); |
845d7e37 |
16 | ok(0,"one"); |
17 | |
68938d83 |
18 | test_fail(+2, 'two'); |
845d7e37 |
19 | |
20 | ok(0,"two"); |
21 | |
22 | test_test("test fail"); |
23 | |
68938d83 |
24 | test_fail(+1, 'one'); |
845d7e37 |
25 | ok(0,"one"); |
26 | test_test("test_fail first"); |
27 | |
28 | # test_diag |
29 | |
30 | use Test::Builder; |
68938d83 |
31 | my $test = Test::Builder->new(); |
845d7e37 |
32 | |
33 | test_diag("this is a test string","so is this"); |
34 | $test->diag("this is a test string\n", "so is this\n"); |
35 | test_test("test diag"); |
36 | |
37 | test_diag("this is a test string","so is this"); |
38 | $test->diag("this is a test string\n"); |
39 | $test->diag("so is this\n"); |
40 | test_test("test diag multi line"); |
41 | |
42 | test_diag("this is a test string"); |
43 | test_diag("so is this"); |
44 | $test->diag("this is a test string\n"); |
45 | $test->diag("so is this\n"); |
46 | test_test("test diag multiple"); |