public void GivenALineDiscount_WhenIsApplicableOnNonLine_ThenShouldReturnFalse() { var sut = new LineDiscount("d", 1, 1, 1); var order = new Order(string.Empty); Assert.IsFalse(sut.IsApplicable(order)); }
public void GivenALineDiscount_WhenIsApplicableOnLine_ThenShouldReturnTrue() { const int PriceThreshold = 100; const int QuantityThreshold = 2; var sut = new LineDiscount("d", 1, QuantityThreshold, PriceThreshold); var line = new Line(new Bike(string.Empty, string.Empty, PriceThreshold), QuantityThreshold + 1); Assert.IsTrue(sut.IsApplicable(line)); }