assertTrue($x) Fail if $x is false
assertFalse($x) Fail if $x is true
assertNull($x) Fail if $x is set
assertNotNull($x) Fail if $x not set
assertIsA($x, $t) Fail if $x is not the class or type $t
assertNotA($x, $t) Fail if $x is of the class or type $t
assertEqual($x, $y) Fail if $x == $y is false
assertNotEqual($x, $y) Fail if $x == $y is true
assertWithinMargin($x, $y, $m) Fail if abs($x - $y) < $m is false
assertOutsideMargin($x, $y, $m) Fail if abs($x - $y) < $m is true
assertIdentical($x, $y) Fail if $x == $y is false or a type mismatch
assertNotIdentical($x, $y) Fail if $x == $y is true and types match
assertReference($x, $y) Fail unless $x and $y are the same variable
assertClone($x, $y) Fail unless $x and $y are identical copies
assertPattern($p, $x) Fail unless the regex $p matches $x
assertNoPattern($p, $x) Fail if the regex $p matches $x
expectError($x) Fail if matching error does not occour
expectException($x) Fail if matching exception is not thrown
ignoreException($x) Swallows any upcoming matching exception
assert($e) Fail on failed expectation object $e
จาก : http://www.simpletest.org/en/unit_test_ ... ation.html
รายชื่อ class ที่ใช้ในการทำสอบของ phpunit
Moderators: mindphp, ผู้ดูแลกระดาน
-
- PHP Super Hero Member
- Posts: 758
- Joined: 08/06/2015 10:07 am
-
- Similar Topics
- Replies
- Views
- Last post
-
-
ผมเปลี่ยนคำสั่ง css ใน class แล้วแต่ class นั้นกลับไปใช้คำสั่งเดิมไม่ยอยให้คำสั่งใหม่ที่ Overrides ไปครับ
by jamepiyawat » 05/09/2019 3:11 pm » in HTML CSS - 2 Replies
- 712 Views
-
Last post by jamepiyawat
05/09/2019 3:26 pm
-
-
- 0 Replies
- 714 Views
-
Last post by Ittichai_chupol
21/11/2019 6:39 pm
-
- 0 Replies
- 584 Views
-
Last post by Patipat
05/08/2019 11:10 am
-
-
ดูนี้ให้หน่อยคับ C++ Base Class และ Devrived Class
by Unis » 11/03/2012 10:18 pm » in Programming - C/C++ & java & Python - 0 Replies
- 1733 Views
-
Last post by Unis
11/03/2012 10:18 pm
-
Who is online
Users browsing this forum: No registered users and 7 guests