static void Cleanup() { using (var context = new EFRecipesEntities()) { context.ExecuteStoreCommand("delete from chapter10.atmwithdrawal"); context.ExecuteStoreCommand("delete from chapter10.atmmachine"); } }
static void Cleanup() { using (var context = new EFRecipesEntities()) { context.ExecuteStoreCommand("delete from chapter15.ProjectEmployee"); context.ExecuteStoreCommand("delete from chapter15.project"); context.ExecuteStoreCommand("delete from chapter15.employee"); } }
static void Cleanup() { using (var context = new EFRecipesEntities()) { context.ExecuteStoreCommand("delete from chapter13.appointment"); context.ExecuteStoreCommand("delete from chapter13.doctor"); context.ExecuteStoreCommand("delete from chapter13.company"); } }
static void Cleanup() { using (var context = new EFRecipesEntities()) { context.ExecuteStoreCommand("delete from chapter8.violation"); context.ExecuteStoreCommand("delete from chapter8.ticket"); context.ExecuteStoreCommand("delete from chapter8.vehicle"); } }
static void Cleanup() { using (var context = new EFRecipesEntities()) { context.ExecuteStoreCommand("delete from chapter2.linktable"); context.ExecuteStoreCommand("delete from chapter2.artist"); context.ExecuteStoreCommand("delete from chapter2.album"); } }
static void Cleanup() { using (var context = new EFRecipesEntities()) { context.ExecuteStoreCommand("delete from chapter12.donation"); } }
protected void Page_Load(object sender, EventArgs e) { if (!this.IsPostBack) { using (var context = new EFRecipesEntities()) { // delete any previous test data context.ExecuteStoreCommand("delete from chapter9.project"); // insert some test data context.Projects.AddObject(new Project { Name = "Trim City Park Trees", AmountAllocated = 8200M, PercentComplete = 75 }); context.SaveChanges(); } } }
static void Cleanup() { using (var context = new EFRecipesEntities()) { context.ExecuteStoreCommand("delete from chapter5.plumber"); context.ExecuteStoreCommand("delete from chapter5.foreman"); context.ExecuteStoreCommand("delete from chapter5.jobsite"); context.ExecuteStoreCommand("delete from chapter5.location"); context.ExecuteStoreCommand("delete from chapter5.tradesman"); context.ExecuteStoreCommand("delete from chapter5.phone"); } }