Gc\Document\ModelTest::testDeleteWithException PHP Method

testDeleteWithException() public method

Test
public testDeleteWithException ( ) : void
return void
    public function testDeleteWithException()
    {
        $configuration = Registry::get('Application')->getConfig();
        if ($configuration['db']['driver'] == 'pdo_mysql') {
            $this->markTestSkipped('Mysql does not thrown exception.');
        }
        $this->setExpectedException('Gc\\Exception');
        $model = new Model();
        $model->setId('test');
        $this->assertFalse($model->delete());
    }