Class OrderThresholdChangeDeliveryModePromotionTest

All Implemented Interfaces:
JaloSessionHolder

public class OrderThresholdChangeDeliveryModePromotionTest extends AbstractPromotionServiceTest
Test for the OrderThresholdChangeDeliveryModePromotion.
  • Constructor Details

    • OrderThresholdChangeDeliveryModePromotionTest

      public OrderThresholdChangeDeliveryModePromotionTest()
  • Method Details

    • setUp

      public void setUp() throws Exception
      Overrides:
      setUp in class AbstractPromotionServiceTest
      Throws:
      Exception
    • testUpgradeDeliveryMode

      public void testUpgradeDeliveryMode() throws CalculationException
      Puts product HW1230-0001 in the cart, sets the delivery mode to "ups" and updates the promotions in "prGroup4" which has an OrderThresholdChangeDeliveryModePromotion. Information for delivery cost in region europe: dhl costs 8.0 Euro, and ups costs 5.0 Euro.
      • without promotion, the delivery mode is "ups" which costs 5.0 Euro,
      • updates promotion, and the delivery mode is "dhl" and still costs 5.0 Euro,
      • updates promotion again, and the delivery mode remains the same as "dhl" and still costs 5.0 Euro,
      • enables the update delivery cost mode, and the delivery mode is still "dhl", but costs 8.0 Euro.
      Throws:
      CalculationException