Including Exception Test

This commit is contained in:
Mayurkumar Vandra
2015-03-01 13:38:17 -05:00
parent 8613f9a06d
commit 3570576eb0

View File

@@ -27,4 +27,12 @@ class StaticFactoryTest extends \PHPUnit_Framework_TestCase
$obj = StaticFactory::factory($type);
$this->assertInstanceOf('DesignPatterns\Creational\StaticFactory\FormatterInterface', $obj);
}
/**
* @expectedException InvalidArgumentException
*/
public function testException()
{
StaticFactory::factory("");
}
}