public void When_IsApplicable_Called_For_OlderVehicles_Then_Result_ShouldBe_True() { // arrange var zeroYearsStatery = new OlderAgeStrategy(); var vehicaleAge = 11; var expected = true; // act var result = zeroYearsStatery.IsApplicable(vehicaleAge); // assert Assert.AreEqual(expected, result); }
public void When_IsApplicable_Called_For_NewOrRelativelyNewVehicles_Then_Result_ShouldBe_False() { // arrange var zeroYearsStatery = new OlderAgeStrategy(); var vehicaleAge = 2; var expected = false; // act var result = zeroYearsStatery.IsApplicable(vehicaleAge); // assert Assert.AreEqual(expected, result); }
public void When_CalculatePriceReductionByMileage_Called_For_ZeroMileage_Then_Result_ShouldBe_Expected() { // arrange var expected = 0m; var decentVehicleStrategy = new OlderAgeStrategy(); var mileage = 0; // act var result = decentVehicleStrategy.CalculatePriceReductionByMileage(mileage); // assert Assert.AreEqual(expected, result); }