Created
July 16, 2011 13:49
-
-
Save yuya-matsushima/1086370 to your computer and use it in GitHub Desktop.
sample test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Utility_helper_tests extends TEST_Controller | |
{ | |
function __construct() | |
{ | |
parent::__construct(); | |
} | |
// h() test | |
function h_str() | |
{ | |
$str = "<>&'"; | |
$test = h($str); | |
$expected = htmlspecialchars($str, ENT_QUOTES, "UTF-8"); | |
$this->unit->run($test, $expected); | |
$this->unit->run($test, 'is_string'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment