public void Can_be_order_more_than_one_coffee_in_the_morning() { var dishes = new List <Dish>() { MorningMenu.Choose(DishType.Drink), MorningMenu.Choose(DishType.Drink) }; var validator = new OrderValidator(); validator.ValidateDishesCount(dishes, TimeOfDay.Morning).Guard(); Assert.Pass(); }
public void Can_be_order_more_than_one_potatoes_in_the_night() { var dishes = new List <Dish>() { NightMenu.Choose(DishType.Side), NightMenu.Choose(DishType.Side) }; var validator = new OrderValidator(); validator.ValidateDishesCount(dishes, TimeOfDay.Night).Guard(); Assert.Pass(); }
public void Throw_exception_when_more_than_once_drink_on_night() { var dishes = new List <Dish>() { NightMenu.Choose(DishType.Drink), NightMenu.Choose(DishType.Drink) }; var validator = new OrderValidator(); Assert.Throws <GFTValidationException>(() => { validator.ValidateDishesCount(dishes, TimeOfDay.Night).Guard(); }); }
public void Throw_exception_when_more_than_once_side_on_morning() { var dishes = new List <Dish>() { MorningMenu.Choose(DishType.Side), MorningMenu.Choose(DishType.Side) }; var validator = new OrderValidator(); Assert.Throws <GFTValidationException>(() => { validator.ValidateDishesCount(dishes, TimeOfDay.Morning).Guard(); }); }