public void Apply_DoesNotApplyWhenNoBasketItems() { var emptyStartingCheckoutState = CheckoutState.Initialise(new BasketItem[0]); var resultingCheckoutState = _giftVoucher.Apply(emptyStartingCheckoutState); AssertDiscountWasNotApplied(resultingCheckoutState); }
public void Apply_DoesNotApplyToEmptyBaskets() { var emptyStartingState = CheckoutState.Initialise(new BasketItem[0]); var offerVoucher = CreateVoucherWithoutRestrictedCategory(); var resultingState = offerVoucher.Apply(emptyStartingState); AssertDiscountWasNotApplied(resultingState); }
private static CheckoutState CheckoutStateWith(params BasketItem[] basketItems) { return(CheckoutState.Initialise(basketItems)); }