diff options
author | Florian Pritz <bluewind@xinu.at> | 2015-02-05 21:38:22 +0100 |
---|---|---|
committer | Florian Pritz <bluewind@xinu.at> | 2015-02-05 21:38:22 +0100 |
commit | a8d1fb52d1dadbd6d4aa4ea50f6f27a967030aa4 (patch) | |
tree | 3e1efc5a9d410836afa7601f16358ad9283906cb /application/third_party/test-more-php/t/testertests_bundle.php | |
parent | 6f1258fbf27b05092ed0712c7d20bafda42074ea (diff) |
Add Test-More
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'application/third_party/test-more-php/t/testertests_bundle.php')
-rwxr-xr-x | application/third_party/test-more-php/t/testertests_bundle.php | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/application/third_party/test-more-php/t/testertests_bundle.php b/application/third_party/test-more-php/t/testertests_bundle.php new file mode 100755 index 000000000..91bf79569 --- /dev/null +++ b/application/third_party/test-more-php/t/testertests_bundle.php @@ -0,0 +1,42 @@ +<?php + + $lib = isset($_SERVER['TESTLIB']) ? $_SERVER['TESTLIB'] : 'Test-More.php'; + require_once($lib); + #plan(3); + + diag('Test of various functions not otherwise broken out.'); + + pass("pass() is ok"); + fail("fail() is not ok"); + + is('Ab3','Ab3','is() is ok'); + isnt('Ab3',123,'isnt() is ok'); + like('yackowackodot','/wacko/',"like() is ok"); + unlike('yackowackodot','/boing/',"unlike() is ok"); + + cmp_ok(12, '>', 10, 'cmp_ok() is ok'); + can_ok($__Test, 'plan' ); + isa_ok($__Test, 'TestMore', 'Default Testing object'); + include_ok('t/goodlib.php'); + require_ok('t/goodpage.php'); + + $foo = array(1,'B','third'); + $oof = array('third','B',1); + + $bar = array('q'=>23,'Y'=>42,); + $rab = array('Y'=>42,'q'=>23,); + + is_deeply($foo,$foo,'is_deeply() is ok'); + isnt_deeply($foo,$bar,'isnt_deeply() is ok'); + + /* + function skip($SkipReason, $num) { + function todo ($why, $howmany) { + function todo_skip ($why, $howmany) { + function todo_start ($why) { + function todo_end () { + */ + + diag("Should fail 1 test, testing fail()"); + done_testing(); +?> |