/** * @expectedException CDbException * @dataProvider fkConfigurationProvider */ public function testYiiException2($config, $transactional) { $this->setConfig($config); $this->startTransaction($transactional); $cat = new Category(); $this->migration->dropRelationTable(); $cat->posts = array(); $cat->save(); $this->endTransaction($transactional); }