securityException = new SecurityException(); } /** * Test the getType() function. * * @return void */ public function testGetType() { $this->assertEquals( 'secure', $this->securityException->getType(), '::getType should always return the type of `secure`.' ); } /** * Test the setMessage() function. * * @return void */ public function testSetMessage() { $sampleMessage = 'foo'; $this->securityException->setMessage($sampleMessage); $this->assertEquals( $sampleMessage, $this->securityException->getMessage(), '::getMessage should always return the message set.' ); } /** * Test the setReason() and corresponding getReason() function. * * @return void */ public function testSetGetReason() { $sampleReason = 'canary'; $this->securityException->setReason($sampleReason); $this->assertEquals( $sampleReason, $this->securityException->getReason(), '::getReason should always return the reason set.' ); } }