Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/1003 payment provider #1243

Merged
merged 9 commits into from
Oct 31, 2024

[Payment] Embedded Payment-Paypal project into Payment project like a…

069f465
Select commit
Loading
Failed to load commit list.
Sign in for the full log view
Merged

Feature/1003 payment provider #1243

[Payment] Embedded Payment-Paypal project into Payment project like a…
069f465
Select commit
Loading
Failed to load commit list.
GitHub Actions / Promotion-Service-Unit-Test-Results succeeded Oct 31, 2024 in 1s

46 passed, 0 failed and 0 skipped

Tests passed successfully

Report Passed Failed Skipped Time
promotion/target/failsafe-reports/TEST-com.yas.promotion.service.PromotionServiceIT.xml 8✅ 52s
promotion/target/surefire-reports/TEST-com.yas.promotion.controller.PromotionControllerTest.xml 11✅ 835ms
promotion/target/surefire-reports/TEST-com.yas.promotion.service.ProductServiceTest.xml 5✅ 3s
promotion/target/surefire-reports/TEST-com.yas.promotion.service.PromotionServiceTest.xml 14✅ 13s
promotion/target/surefire-reports/TEST-com.yas.promotion.validation.PromotionValidatorTest.xml 8✅ 69ms

✅ promotion/target/failsafe-reports/TEST-com.yas.promotion.service.PromotionServiceIT.xml

8 tests were completed in 52s with 8 passed, 0 failed and 0 skipped.

Test suite Passed Failed Skipped Time
com.yas.promotion.service.PromotionServiceIT 8✅ 52s

✅ com.yas.promotion.service.PromotionServiceIT

✅ testUpdatePromotion_whenPromotionIsEmpty_throwNotFoundException
✅ createPromotion_ThenSuccess
✅ createPromotion_WhenExistedSlug_ThenDuplicatedExceptionThrown
✅ testUpdatePromotion_whenNormalCase_updatePromotion
✅ testDeletePromotion_normalCase_deletePromotion
✅ testDeletePromotion_existsPromotionUsageByPromotionId_throwBadRequestException
✅ getPromotionLists_existsPromotions_ThenPromotionListVm
✅ createPromotion_WhenEndDateBeforeStartDate_ThenDateRangeExceptionThrown

✅ promotion/target/surefire-reports/TEST-com.yas.promotion.controller.PromotionControllerTest.xml

11 tests were completed in 835ms with 11 passed, 0 failed and 0 skipped.

Test suite Passed Failed Skipped Time
com.yas.promotion.controller.PromotionControllerTest 11✅ 835ms

✅ com.yas.promotion.controller.PromotionControllerTest

✅ testDeletePromotion_whenValidRequest_deleteSuccess
✅ testCreatePromotion_whenNameIsOverMaxLength_thenReturnBadRequest
✅ verify_promotion_with_valid_data_returns_expected_result
✅ testUpdatePromotion_whenValidRequest_thenReturnPromotionDetailVm
✅ testCreatePromotion_whenNameIsBlank_thenReturnBadRequest
✅ testCreatePromotion_whenDiscountPercentageIsGreaterThanHundred_thenReturnBadRequest
✅ test_getPromotion_success
✅ testCreatePromotion_whenDiscountPercentageIsSmallerThanZero_thenReturnBadRequest
✅ testListPromotions_whenValidRequest_thenReturnPromotionListVm
✅ testCreatePromotion_whenDiscountAmountIsSmallerThanZero_thenReturnBadRequest
✅ testCreatePromotion_whenRequestIsValid_thenReturnOk

✅ promotion/target/surefire-reports/TEST-com.yas.promotion.service.ProductServiceTest.xml

5 tests were completed in 3s with 5 passed, 0 failed and 0 skipped.

Test suite Passed Failed Skipped Time
com.yas.promotion.service.ProductServiceTest 5✅ 3s

✅ com.yas.promotion.service.ProductServiceTest

✅ testGetProductByIds_ifNormalCase_returnProductVms
✅ testGetBrandByIds_ifNormalCase_returnBrandVms
✅ testGetProductByCategoryIds_ifNormalCase_returnProductVms
✅ testGetCategoryByIds_ifNormalCase_returnCategoryGetVms
✅ testGetProductByBrandIds_ifNormalCase_returnProductVms

✅ promotion/target/surefire-reports/TEST-com.yas.promotion.service.PromotionServiceTest.xml

14 tests were completed in 13s with 14 passed, 0 failed and 0 skipped.

Test suite Passed Failed Skipped Time
com.yas.promotion.service.PromotionServiceTest 14✅ 13s

✅ com.yas.promotion.service.PromotionServiceTest

✅ verifyPromotion_applyToProduct_ThenSuccess
✅ testVerifyPromotion_ProductNotFound
✅ verifyPromotion_applyToCategory_ThenSuccess
✅ testVerifyPromotion_PromotionNotFound
✅ getPromotion_WhenNotExist_ThenNotFoundExceptionThrown
✅ createPromotion_ThenSuccess
✅ createPromotion_WhenExistedSlug_ThenDuplicatedExceptionThrown
✅ testVerifyPromotion_ExhaustedUsageQuantity
✅ getPromotion_ThenSuccess
✅ verifyPromotion_applyToBrand_ThenSuccess
✅ createPromotion_WhenCouponCodeAlreadyExisted_ThenDuplicatedExceptionThrown
✅ getPromotionList_ThenSuccess
✅ createPromotion_WhenEndDateBeforeStartDate_ThenDateRangeExceptionThrown
✅ testVerifyPromotion_InvalidOrderPrice

✅ promotion/target/surefire-reports/TEST-com.yas.promotion.validation.PromotionValidatorTest.xml

8 tests were completed in 69ms with 8 passed, 0 failed and 0 skipped.

Test suite Passed Failed Skipped Time
com.yas.promotion.validation.PromotionValidatorTest 8✅ 69ms

✅ com.yas.promotion.validation.PromotionValidatorTest

✅ testIsValid_whenUsageLimitIs0_isValidFalse
✅ testIsValid_whenApplyToIsProductAndProductIdsIdEmpty_isValidFalse
✅ testIsValid_whenAppleToCategory_isValidTrue
✅ testIsValid_whenDiscountTypeIsFixedAndDiscountAmountIs0_isValidFalse
✅ testIsValid_whenApplyToIsCategoryAndCategoryIdsIdEmpty_isValidFalse
✅ testIsValid_whenAppleToBrand_isValidTrue
✅ testIsValid_whenApplyToIsBrandAndBrandIdsIdEmpty_isValidFalse
✅ testIsValid_whenAppleToProduct_isValidTrue