/** * TestCases must call this method inside tearDown(). */ public function onTearDown() { parent::onTearDown(); $this->getConnection()->getConnection()->exec('SET FOREIGN_KEY_CHECKS=1;'); }