public void DropTableTest() { FAKE_SqlLiteDatabase db = CreateTestDatabase(String.Format("{0}", dbConstants.ID)); _w.output("here"); try { db.InsertData(dbConstants.table_name, new string[3] { dbConstants.STATUS, dbConstants.XML, dbConstants.GUID } , new object[3] { "boo status", "boo xml", "GUID_A" }); Assert.True(db.TableExists(dbConstants.table_name)); db.DropTableIfExists(dbConstants.table_name); Assert.True(db.TableExists(dbConstants.table_name)); } catch (Exception) { } }
public void TableDoesExist() { FAKE_SqlLiteDatabase db = new FAKE_SqlLiteDatabase (test_database_name); db.DropTableIfExists(dbConstants.table_name); _w.output ("here1"); Assert.False (db.TableExists (dbConstants.table_name)); _w.output ("here"); CreateTestDatabase (String.Format ("{0}", dbConstants.ID)); _w.output ("here"); try { db.InsertData (dbConstants.table_name, new string[3] { dbConstants.STATUS, dbConstants.XML, dbConstants.GUID } , new object[3] {"boo status", "boo xml", "GUID_A"}); Assert.True (db.TableExists (dbConstants.table_name)); } catch (Exception) { } }