public void TestDelete() { var orderitems = oir.GetOrderItems(); int orderitemscount = orderitems.Count(); oir.Delete(orderitems[orderitemscount - 1].Id); var lastorderitem = oir.GetOrderItems().Last(); Assert.AreEqual(lastorderitem.Id, OI.Id, "Id should be equal"); }