diff options
author | admin <devnull@localhost> | 2006-09-28 18:47:05 +0200 |
---|---|---|
committer | admin <devnull@localhost> | 2006-09-28 18:47:05 +0200 |
commit | e721cc7c81af84dcabce2992fa693ce36b605a19 (patch) | |
tree | 97552d02f6ad8ab38887e110443d8982e5e17848 /system/libraries/Unit_test.php | |
parent | 89ed1b33638691ea5e9368dcd5973a179baa8105 (diff) |
Diffstat (limited to 'system/libraries/Unit_test.php')
-rw-r--r-- | system/libraries/Unit_test.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/system/libraries/Unit_test.php b/system/libraries/Unit_test.php index b2f4bf8cd..d3e151328 100644 --- a/system/libraries/Unit_test.php +++ b/system/libraries/Unit_test.php @@ -57,8 +57,8 @@ class CI_Unit_test { if ($this->active == FALSE) return; - if (in_array($expected, array('is_string', 'is_bool', 'is_true', 'is_false', 'is_int', 'is_numeric', 'is_float', 'is_double', 'is_array', 'is_null'))) - { + if ($expected !== 0 AND in_array($expected, array('is_string', 'is_bool', 'is_true', 'is_false', 'is_int', 'is_numeric', 'is_float', 'is_double', 'is_array', 'is_null'))) + { $expected = str_replace('is_float', 'is_double', $expected); $result = ($expected($test)) ? TRUE : FALSE; $extype = str_replace(array('true', 'false'), 'bool', str_replace('is_', '', $expected)); |