public void DeleteContent_ShouldReturnTrue() { //Arrange //Act bool deleteResult = _repo.RemoveMealFromList(_mealContent.MealName); //Assert Assert.IsTrue(deleteResult); }
public void DeleteAnExistingMeal() { DisplayAllMeals(); Console.WriteLine("Please enter a meal to be removed: "); string mealName = Console.ReadLine().ToLower(); bool wasDeleted = _mealContents.RemoveMealFromList(mealName); if (wasDeleted) { Console.WriteLine("The meal was deleted successfully"); } else { Console.WriteLine("Could not remove the meal"); } }
private void DeleteMealFromMenu() { ViewAllMeals(); Console.WriteLine("Please enter the name of meal"); string mealAnswer = Console.ReadLine(); bool wasDeleted = _mealRepo.RemoveMealFromList(mealAnswer); if (wasDeleted) { Console.WriteLine("The meal was removed from the menu."); } else { Console.WriteLine("The meal could not be removed successfully"); } }