Moving setExpectedException

This commit is contained in:
Vyacheslav Agafonov
2011-12-02 12:25:47 +04:00
parent 1f1551aea1
commit 0fda3de8b5
16 changed files with 38 additions and 29 deletions

View File

@ -61,11 +61,12 @@ class RegistryTest extends PHPUnit_Framework_TestCase
*/
public function testIsRegistered()
{
$this->setExpectedException('PHPUnit_Framework_Error');
$this->assertFalse(Registry::isRegistered(43));
$this->_registry->set(3, 'three');
$this->assertTrue(Registry::isRegistered(3));
$this->setExpectedException('PHPUnit_Framework_Error');
$this->assertFalse(Registry::isRegistered(null));
}
}