public function tearDown() { if (count($this->tables)) { if (in_array('BlockTypes', $this->tables)) { $this->tables[] = 'btCoreScrapbookDisplay'; } foreach ($this->tables as $table) { // drop table $conn = $this->getConnection(); $pdo = $conn->getConnection(); $pdo->exec("DROP TABLE IF EXISTS `{$table}`;"); } } $allTables = $this->getDataSet($this->fixtures)->getTableNames(); foreach ($allTables as $table) { // drop table $conn = $this->getConnection(); $pdo = $conn->getConnection(); $pdo->exec("DROP TABLE IF EXISTS `{$table}`;"); } $db = Loader::db(); $db->getEntityManager()->clear(); \CacheLocal::flush(); parent::tearDown(); }
public function refreshCache() { CacheLocal::flush(); }