Class CouponCodeGenerationWebServicesTest

All Implemented Interfaces:
JaloSessionHolder

@IntegrationTest public class CouponCodeGenerationWebServicesTest extends ServicelayerTest
  • Field Details

  • Constructor Details

    • CouponCodeGenerationWebServicesTest

      public CouponCodeGenerationWebServicesTest()
  • Method Details

    • setUp

      public void setUp() throws Exception
      Throws:
      Exception
    • testPutGenerateCodesWithoutAuthorization

      public void testPutGenerateCodesWithoutAuthorization()
    • testPutGenerateCodes

      public void testPutGenerateCodes()

      the test is for occ api of "/couponservices/v2/multicodecoupon/generate/{couponId}/{batchsize}" This endpoint generates a batch of the multi-code coupon codes for a provided couponId and batch size

      Parameters:
      batchSize -
      couponId -
    • testGetGeneratedCouponCodesUnauthorized

      public void testGetGeneratedCouponCodesUnauthorized() throws Exception
      Throws:
      Exception
    • testGetGeneratedCouponCodes

      public void testGetGeneratedCouponCodes() throws Exception

      test case for occ api of "/couponcodes​/{couponId}​/{mediaCode}" the api retrieves the generated coupon codes for a multi-code coupon given its media code.

      Parameters:
      couponId -
      mediaCode -
      Throws:
      Exception
    • testGetMultiCodeCouponWithGeneratedCodes

      public void testGetMultiCodeCouponWithGeneratedCodes() throws Exception

      the test is for occ api of "/couponservices/v2/multicodecoupon/generate/{couponId}/{batchsize}" This endpoint generates a batch of the multi-code coupon codes for a provided couponId and batch size

      Parameters:
      batchSize -
      couponId - meanwhile the test also for occ api "/couponservices​/v2​/multicodecoupon​/get​/{couponId}" which retrieves a multi-code coupon for a given couponId
      couponId -
      Throws:
      Exception
    • shouldProvideCodeGenerationConfiguration

      public void shouldProvideCodeGenerationConfiguration()
    • shouldProvideCodeGenerationConfigurationSortedByNameWithDesc

      public void shouldProvideCodeGenerationConfigurationSortedByNameWithDesc()
    • shouldProvideCodeGenerationConfigurationPaged

      public void shouldProvideCodeGenerationConfigurationPaged()