function test_passwordError() { $r = new Register(); $r->passwordError("", ""); $this->assertFalse(empty($r->noPassword)); $this->assertFalse(empty($r->noConfirmPassword)); $this->assertTrue(empty($r->noPasswordMatch)); $r = new Register(); $r->passwordError("klink", "klink"); $this->assertTrue(empty($r->noPassword)); $this->assertTrue(empty($r->noConfirmPassword)); $this->assertTrue(empty($r->noPasswordMatch)); $r = new Register(); $r->passwordError("klink", ""); $this->assertTrue(empty($r->noPassword)); $this->assertFalse(empty($r->noConfirmPassword)); $this->assertTrue(empty($r->noPasswordMatch)); $r = new Register(); $r->passwordError("", "klink"); $this->assertFalse(empty($r->noPassword)); $this->assertTrue(empty($r->noConfirmPassword)); $this->assertTrue(empty($r->noPasswordMatch)); }