pageHTML ("http://localhost"); $this->assertSame (!! strpos ($res, "
pageHTML ("http://localhost", "MESSAGE"); $this->assertSame (!! strpos ($res, "MESSAGE"), true); } public function test_URL_1 () { $auth = new auth (); $res = $auth->pageHTML ("http://localhost", "MESSAGE", "URL/TEST"); $this->assertSame (!! strpos ($res, "URL/TEST"), true); } public function test_alreadyAuth_1 () { // Not Authenticated $auth = new auth (); $res = $auth->pageHTML ("http://localhost", "MESSAGE", "URL/TEST", false); $this->assertSame (!! strpos ($res, "Please sign in"), true); } public function test_alreadyAuth_2 () { // Authenticated $auth = new auth (); $res = $auth->pageHTML ("http://localhost", "", "", "AUTHENTICATED USER"); $this->assertSame (!! strpos ($res, "AUTHENTICATED USER"), true); } }