Commit | Line | Data |
---|---|---|
dfa18578 JH |
1 | use FilterOnlyTest qr/not ok/ => "ok", "bad" => "ok", fail => "die"; |
2 | print "1..9\n"; | |
3 | ||
4 | sub fail { print "ok ", $_[0], "\n" } | |
5 | sub ok { print "ok ", $_[0], "\n" } | |
6 | ||
7 | print "not ok 1\n"; | |
8 | print "bad 2\n"; | |
9 | ||
10 | fail(3); | |
11 | &fail(4); | |
12 | ||
13 | print "not " unless "whatnot okapi" eq "whatokapi"; | |
14 | print "ok 5\n"; | |
15 | ||
16 | ok 7 unless not ok 6; | |
17 | ||
18 | no FilterOnlyTest; # THE FUN STOPS HERE | |
19 | ||
20 | print "not " unless "not ok" =~ /^not /; | |
21 | print "ok 8\n"; | |
22 | ||
23 | print "not " unless "bad" =~ /bad/; | |
24 | print "ok 9\n"; |