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

fix: (CXSPA-9098)-Coupon Codes is used in Coupon Campaign URL #19739

Open
wants to merge 22 commits into
base: develop
Choose a base branch
from

Conversation

crisli001
Copy link

… for SPA UI

@crisli001 crisli001 marked this pull request as ready for review December 10, 2024 03:21
@crisli001 crisli001 requested review from a team as code owners December 10, 2024 03:21
@crisli001 crisli001 requested a review from ssisali December 10, 2024 03:22
Copy link

cypress bot commented Dec 10, 2024

spartacus    Run #46459

Run Properties:  status check passed Passed #46459  •  git commit 804095d71f ℹ️: Merge cd3b128e51bf3eba3c8fb8c050c075ce5f9f5c3b into 3a234205e59792f259e103c3686d...
Project spartacus
Branch Review bugfix/CXSPA-9098
Run status status check passed Passed #46459
Run duration 03m 55s
Commit git commit 804095d71f ℹ️: Merge cd3b128e51bf3eba3c8fb8c050c075ce5f9f5c3b into 3a234205e59792f259e103c3686d...
Committer crisli001
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 3
Tests that did not run due to a developer annotating a test with .skip  Pending 2
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 125
View all changes introduced in this branch ↗︎

@github-actions github-actions bot marked this pull request as draft December 10, 2024 07:46
@crisli001 crisli001 marked this pull request as ready for review December 10, 2024 08:37
Copy link
Contributor

Merge Checks Failed

Please push a commit to re-trigger the build. 
To push an empty commit you can use `git commit --allow-empty -m "Trigger Build"`

@github-actions github-actions bot marked this pull request as draft December 10, 2024 08:51
@crisli001 crisli001 marked this pull request as ready for review December 10, 2024 08:51
@github-actions github-actions bot marked this pull request as draft December 18, 2024 09:46
@crisli001 crisli001 marked this pull request as ready for review December 18, 2024 09:46
Copy link
Contributor

Merge Checks Failed

Please push a commit to re-trigger the build. 
To push an empty commit you can use `git commit --allow-empty -m "Trigger Build"`

@github-actions github-actions bot marked this pull request as draft December 18, 2024 09:58
@crisli001 crisli001 marked this pull request as ready for review December 18, 2024 09:58
@crisli001 crisli001 changed the title CXSPA-9098, fix the issue Coupon Codes is used in Coupon Campaign URL… fix: (CXSPA-9098)-fix the issue Coupon Codes is used in Coupon Campaign URL… Dec 18, 2024
@crisli001 crisli001 changed the title fix: (CXSPA-9098)-the issue Coupon Codes is used in Coupon Campaign URL fix: (CXSPA-9098)-Coupon Codes is used in Coupon Campaign URL Dec 18, 2024
@@ -429,6 +429,7 @@ if (environment.cpq) {
a11yWrapReviewOrderInSection: true,
enableCarouselCategoryProducts: true,
enableSecurePasswordValidation: true,
enableClaimCustomerCouponWithCodeInRequestBody: true,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is true that we want to enable all toggles in our demo app, but in this exact case, if I understand correctly, the API will be available starting from some future version.
If yes - we toggle set to true, our e2e tests will be broken because this functionality will not work before the servers update.
In this case i think it should be false.
I also thinking, maybe it is good to add this information to the toggle JSdoc? Some info telling that if you enabling this toggle you should have cx in version FP8

Copy link
Author

@crisli001 crisli001 Dec 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, sorry for forget to tell you that we already integrated the new endpoints into Commerce since 2211.28, see following comment. And more details see https://sap-cx.slack.com/archives/C084MGZU2MP/p1733746463727399.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, in this case it could be true, agree.
I run all e2e tests against your branch, and there are couple of e2e tests in different libs that start failing after this change.
Here you can check the result https://cloud.cypress.io/projects/k3nmep/runs/46437/overview?runStatus=FAILED&runStatus=CANCELLED&runStatus=ERRORED&runStatus=PASSED&runStatus=RUNNING&runStatus=NOTESTS&runStatus=TIMEDOUT&roarHideRunsWithDiffGroupsAndTags=1
image

The first one "Order history" is flaky and probably not related to your changes, it failed already earlier, but the other ones seems to be related to coupon.

Can you check it please on your side?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks, sure, will check and update

Copy link
Author

@crisli001 crisli001 Dec 20, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @rmch91 , I have checked the failed cypress test cases except "Order history" which think not related my changes, yeah, the other failed cases is related with my changes, so I have updated the case with a little changes, now after update local running shows it is ok:
image

I have no access to trigger the whole e2e cypress tests, to see whether the fix(update) for failed test cases work or not, could you help re-run the whole e2e cypress tests based on the fix branch after the cases updated?
Thanks a lot.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Many thanks, I run it and waiting for the result

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rmch91
Copy link
Contributor

rmch91 commented Dec 18, 2024

Hi @crisli001. You add a comment for your toggle in feature-toggles.ts, there is nothing further you need to do for documentation. Thanks for asking 🙏

@github-actions github-actions bot marked this pull request as draft December 19, 2024 05:48
@crisli001 crisli001 marked this pull request as ready for review December 19, 2024 05:48
Copy link
Contributor

Merge Checks Failed

Please push a commit to re-trigger the build. 
To push an empty commit you can use `git commit --allow-empty -m "Trigger Build"`

@github-actions github-actions bot marked this pull request as draft December 19, 2024 06:39
@crisli001 crisli001 marked this pull request as ready for review December 19, 2024 06:41
@crisli001
Copy link
Author

crisli001 commented Dec 19, 2024

Hi @rmch91, I have updated again, could you help review again? Thanks a lot.

@crisli001 crisli001 requested a review from rmch91 December 19, 2024 07:26
Copy link

cypress bot commented Dec 19, 2024

spartacus    Run #46460

Run Properties:  status check failed Failed #46460  •  git commit cd3b128e51: Trigger Build
Project spartacus
Branch Review bugfix/CXSPA-9098
Run status status check failed Failed #46460
Run duration 13m 06s
Commit git commit cd3b128e51: Trigger Build
Committer Cris Li
View all properties for this run ↗︎

Test results
Tests that failed  Failures 3
Tests that were flaky  Flaky 2
Tests that did not run due to a developer annotating a test with .skip  Pending 22
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 811
View all changes introduced in this branch ↗︎

Tests for review

Failed  regression/asm/customer360.e2e.cy.ts • 1 failed test • B2C

View Output Video

Test Artifacts
Assisted Service Module > Promotion > should be able to remove customer coupon for customer coupon (CXSPA-3945) Test Replay Screenshots Video
Failed  regression/multi-dimensional/multi-dimensional-checkout-as-guest.e2e.cy.ts • 1 failed test • B2C

View Output Video

Test Artifacts
... > should perform checkout as guest, create an account and verify guest data, and verify cart persists after registering Test Replay Screenshots Video
Failed  b2b/regression/asm/customer360-promotion.e2e.cy.ts • 1 failed test • B2B

View Output Video

Test Artifacts
Assisted Service Module > B2B Asm Customer360 Promotion > should be able to remove customer coupon for customer coupon (CXSPA-3945) Test Replay Screenshots Video
Flakiness  my-account/order-history-orders-flow.e2e.cy.ts • 1 flaky test • B2C

View Output Video

Test Artifacts
Order History with orders > Mobile > should sort the orders table by given code Test Replay Screenshots Video
Flakiness  redirects/auth-redirects.e2e.cy.ts • 1 flaky test • B2C

View Output Video

Test Artifacts
Redirect after auth > should redirect back after the forced login when access token expired and page was refreshed Test Replay Screenshots Video

@github-actions github-actions bot marked this pull request as draft December 20, 2024 01:46
@crisli001 crisli001 marked this pull request as ready for review December 20, 2024 01:47
Copy link
Contributor

Merge Checks Failed

Please push a commit to re-trigger the build. 
To push an empty commit you can use `git commit --allow-empty -m "Trigger Build"`

@github-actions github-actions bot marked this pull request as draft December 20, 2024 01:52
@crisli001 crisli001 marked this pull request as ready for review December 20, 2024 02:00
@crisli001
Copy link
Author

Hi @rmch91 , I have updated cypress test cases, could you help re-run the whole cypress tests and review the PR again?
Thanks a lot.

@github-actions github-actions bot marked this pull request as draft December 22, 2024 06:22
@crisli001 crisli001 marked this pull request as ready for review December 22, 2024 06:29
@github-actions github-actions bot marked this pull request as draft December 22, 2024 06:57
@crisli001 crisli001 marked this pull request as ready for review December 22, 2024 06:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants