mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-08-02 13:07:27 +02:00
Including Exception Test
This commit is contained in:
@@ -27,4 +27,12 @@ class StaticFactoryTest extends \PHPUnit_Framework_TestCase
|
|||||||
$obj = StaticFactory::factory($type);
|
$obj = StaticFactory::factory($type);
|
||||||
$this->assertInstanceOf('DesignPatterns\Creational\StaticFactory\FormatterInterface', $obj);
|
$this->assertInstanceOf('DesignPatterns\Creational\StaticFactory\FormatterInterface', $obj);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @expectedException InvalidArgumentException
|
||||||
|
*/
|
||||||
|
public function testException()
|
||||||
|
{
|
||||||
|
StaticFactory::factory("");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user