Delete always content from table master_slave_table between tests. #203

Merged
merged 1 commit into from Oct 5, 2012
Jump to file or symbol
Failed to load files and symbols.
+4 −1
Split
@@ -27,9 +27,12 @@ public function setUp()
$sm = $this->_conn->getSchemaManager();
$sm->createTable($table);
- $this->_conn->insert('master_slave_table', array('test_int' => 1));
+
} catch(\Exception $e) {
}
+
+ $this->_conn->executeUpdate('DELETE FROM master_slave_table');
+ $this->_conn->insert('master_slave_table', array('test_int' => 1));
@stof

stof Sep 23, 2012

Member

you should keep it in the try/catch block

@kimhemsoe

kimhemsoe Sep 23, 2012

Member

How will we then ever execute the line there delete rows from previous tests ?

}
public function createMasterSlaveConnection($keepSlave = false)