summaryrefslogtreecommitdiffstats
path: root/system/libraries/Unit_test.php
diff options
context:
space:
mode:
authorAlex Bilbie <alex@alexbilbie.com>2012-06-02 12:12:16 +0200
committerAlex Bilbie <alex@alexbilbie.com>2012-06-02 12:12:16 +0200
commitd261b1e89c3d4d5191036d5a5660ef6764e593a0 (patch)
tree13ba5eeaf8f1d2cf608d31622de9ef2c3ef29b99 /system/libraries/Unit_test.php
parent773ccc318f2769c9b7579630569b5d8ba47b114b (diff)
Replaced `==` with `===` and `!=` with `!==` in /system/libraries
Diffstat (limited to 'system/libraries/Unit_test.php')
-rw-r--r--system/libraries/Unit_test.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/system/libraries/Unit_test.php b/system/libraries/Unit_test.php
index 6ec2dcd5d..a87cf7e14 100644
--- a/system/libraries/Unit_test.php
+++ b/system/libraries/Unit_test.php
@@ -93,7 +93,7 @@ class CI_Unit_test {
*/
public function run($test, $expected = TRUE, $test_name = 'undefined', $notes = '')
{
- if ($this->active == FALSE)
+ if ($this->active === FALSE)
{
return FALSE;
}
@@ -106,7 +106,7 @@ class CI_Unit_test {
}
else
{
- $result = ($this->strict == TRUE) ? ($test === $expected) : ($test == $expected);
+ $result = ($this->strict === TRUE) ? ($test === $expected) : ($test === $expected);
$extype = gettype($expected);
}
@@ -155,13 +155,13 @@ class CI_Unit_test {
foreach ($res as $key => $val)
{
- if ($key == $CI->lang->line('ut_result'))
+ if ($key === $CI->lang->line('ut_result'))
{
- if ($val == $CI->lang->line('ut_passed'))
+ if ($val === $CI->lang->line('ut_passed'))
{
$val = '<span style="color: #0C0;">'.$val.'</span>';
}
- elseif ($val == $CI->lang->line('ut_failed'))
+ elseif ($val === $CI->lang->line('ut_failed'))
{
$val = '<span style="color: #C00;">'.$val.'</span>';
}