public void testClearBikeListMethod() { //arrange FacadeManagement facade = FacadeManagement.getInstance(); //act facade.clearBikeList(); //assert (If the bike list is empty the bike cost is 0) Assert.AreEqual(0, facade.getTotalBikesCost(), "Facade clear bike method do not implemented correctly"); }
private void cancelOrderBtn_Click(object sender, RoutedEventArgs e) { //If the order is cancelled the stock needs to be updated back and the list with the bikes cleared facade.updateStockBack(); facade.clearBikeList(); //Return to the main window MainWindow window = new MainWindow(); window.Show(); this.Close(); }