public void EditCategoryDiscount() { CategoryDiscount expected = new CategoryDiscount("d2", "WanderlandItems", "T", DateTime.Parse("1/1/2018"), DateTime.Parse("31/12/2018"), 50); handler.AddCategoryDiscount(expected); var find = handler.GetCategoryDiscount("WanderlandItems", "T"); Assert.AreEqual(expected, find); expected.StartDate = DateTime.Parse("15/07/2018"); handler.EditCategoryDiscount(expected); find = handler.GetCategoryDiscount("WanderlandItems", "T"); Assert.AreEqual(expected, find); }