From: Steve Peters Date: Sun, 9 Jul 2006 20:51:48 +0000 (+0000) Subject: Hmmm...patch didn't warn about rejects in tbt_01basic.t. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=dd2bedf46dbaa8f19996744e67544bd24fd733b3;p=p5sagit%2Fp5-mst-13.2.git Hmmm...patch didn't warn about rejects in tbt_01basic.t. p4raw-id: //depot/perl@28517 --- diff --git a/lib/Test/Simple/t/tbt_01basic.t b/lib/Test/Simple/t/tbt_01basic.t index 28cf4cb..81eeae6 100644 --- a/lib/Test/Simple/t/tbt_01basic.t +++ b/lib/Test/Simple/t/tbt_01basic.t @@ -29,34 +29,44 @@ ok(2,"two"); test_test("multiple tests"); test_out("not ok 1 - should fail"); -test_err("# Failed test ($0 at line 35)"); +test_err("# Failed test ($0 at line 28)"); test_err("# got: 'foo'"); test_err("# expected: 'bar'"); is("foo","bar","should fail"); test_test("testing failing"); -test_out("not ok 1"); -test_out("not ok 2"); test_fail(+2); test_fail(+1); fail(); fail(); test_test("testing failing on the same line with no name"); -test_out("not ok 1 - name"); -test_out("not ok 2 - name"); -test_fail(+2); -test_fail(+1); -fail("name"); fail("name"); +test_fail(+2, 'name'); +test_fail(+1, 'name_two'); +fail("name"); fail("name_two"); test_test("testing failing on the same line with the same name"); test_out("not ok 1 - name # TODO Something"); -test_err("# Failed (TODO) test ($0 at line 59)"); +my $line = __LINE__ + 4; +test_err("# Failed (TODO) test ($0 at line $line)"); TODO: { local $TODO = "Something"; fail("name"); } test_test("testing failing with todo"); +test_pass(); +pass(); +test_test("testing passing with test_pass()"); + +test_pass("some description"); +pass("some description"); +test_test("testing passing with test_pass() and description"); + +test_pass("one test"); +test_pass("... and another"); +ok(1, "one test"); +ok(1, "... and another"); +test_test("testing pass_test() and multiple tests");