public void AddMultipleFoodItemsToList() { OrderList orderList = new OrderList(); orderList.AddStarter(StarterMenu.Chips); orderList.AddStarter(StarterMenu.HotWings); orderList.AddMain(MainMenu.CheeseBurger); orderList.AddMain(MainMenu.CheeseBurger); orderList.AddMain(MainMenu.PepperoniPizza); Assert.AreEqual(5, orderList.GetCountOfItems()); }
public void GetTotalOfOneMainAfterDelete() { OrderList orderList = new OrderList(); orderList.AddMain(MainMenu.CheeseBurger); orderList.AddMain(MainMenu.PepperoniPizza); Till till = new Till(orderList); orderList.DeleteMain(MainMenu.PepperoniPizza); Assert.AreEqual("�00", till.GetTotalFromList()); }
public void MainPriceIsReturned() { OrderList orderList = new OrderList(); orderList.AddMain(MainMenu.CheeseBurger); Assert.AreEqual(7.00, orderList.GetList()[0].Price); }
public void AddMainToList() { OrderList orderList = new OrderList(); orderList.AddMain(MainMenu.CheeseBurger); Assert.AreEqual(1, orderList.GetCountOfItems()); }
public void DeletingMultipleFoodItemsFromList() { OrderList orderList = new OrderList(); orderList.AddStarter(StarterMenu.Chips); orderList.AddStarter(StarterMenu.Chips); orderList.AddMain(MainMenu.CheeseBurger); orderList.AddMain(MainMenu.CheeseBurger); orderList.AddMain(MainMenu.CheeseBurger); orderList.AddMain(MainMenu.CheeseBurger); orderList.DeleteStarter(StarterMenu.Chips); orderList.DeleteMain(MainMenu.CheeseBurger); orderList.DeleteMain(MainMenu.CheeseBurger); Assert.AreEqual(3, orderList.GetCountOfItems()); }
public void DeleteMainFromList() { OrderList orderList = new OrderList(); orderList.AddMain(MainMenu.CheeseBurger); orderList.DeleteMain(MainMenu.CheeseBurger); Assert.AreEqual(0, orderList.GetCountOfItems()); }
public void UpdateMain() { OrderList orderList = new OrderList(); orderList.AddMain(MainMenu.CheeseBurger); orderList.UpdateMain(MainMenu.CheeseBurger, MainMenu.SteakChips); Assert.AreEqual(1, orderList.GetCountOfItems()); Assert.AreEqual(MainMenu.SteakChips, orderList.GetList()[0].Meal); }
public void GetTotalOfOneMain() { OrderList orderList = new OrderList(); orderList.AddMain(MainMenu.CheeseBurger); Till till = new Till(orderList); Assert.AreEqual("�00", till.GetTotalFromList()); }
public void GetTotalOfMultipleFoodItems(int numOfStarters, int numOfMains, string expectedCost) { OrderList orderList = new OrderList(); for (int i = 0; i < numOfStarters; i++) { orderList.AddStarter(StarterMenu.Chips); } for (int i = 0; i < numOfMains; i++) { orderList.AddMain(MainMenu.CheeseBurger); } Till till = new Till(orderList); Assert.AreEqual(expectedCost, till.GetTotalFromList()); }