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

Tests for BNPL checkouts failing. #8798

Open
brettshumaker opened this issue May 8, 2024 · 0 comments
Open

Tests for BNPL checkouts failing. #8798

brettshumaker opened this issue May 8, 2024 · 0 comments
Labels
category: e2e Issues and PRs related to e2e tests. e2e: broken test e2e test itself is not working as expected. focus: checkout payments needs triage Manually put issue into triage process. priority: high The issue/PR is high priority—it affects lots of customers substantially, but not critically. type: bug The issue is a confirmed bug.

Comments

@brettshumaker
Copy link
Contributor

Description

These tests are primarily failing due to async callback timeouts, though one times out waiting on an XPath selector.

This is the first job I saw it failing on and is likely related (unclear how yet) since it added content to the BNPL checkout page items.

Spec: tests/e2e/specs/wcpay/shopper/shopper-bnpls-checkout.spec.js

Output from the test failure:

● BNPL checkout › Checkout with Afterpay, carding protection false › should successfully place order with Afterpay

    : Timeout - Async callback was not invoked within the 100000 ms timeout specified by jest.setTimeout.Timeout - Async callback was not invoked within the 100000 ms timeout specified by jest.setTimeout.Error:
● BNPL checkout › Checkout with Affirm, carding protection true › should successfully place order with Affirm

    : Timeout - Async callback was not invoked within the 100000 ms timeout specified by jest.setTimeout.Timeout - Async callback was not invoked within the 100000 ms timeout specified by jest.setTimeout.Error:
● BNPL checkout › Checkout with Afterpay, carding protection true › should successfully place order with Afterpay

    TimeoutError: waiting for XPath "//*[self::button or self::a][contains(text(), 'Authorize Test Payment')]" failed: timeout 100000ms exceeded

      79 | 					// This XPath selector matches the Authorize Payment button, that is either a button or an anchor.
      80 | 					const xPathAuthorizePaymentButton = `//*[self::button or self::a][contains(text(), 'Authorize Test Payment')]`;
    > 81 | 					await page.waitForXPath( xPathAuthorizePaymentButton );
         | 					           ^
      82 | 					const [ stripeButton ] = await page.$x(
      83 | 						xPathAuthorizePaymentButton
      84 | 					);
  ● BNPL checkout › Checkout with Afterpay, carding protection true › should successfully place order with Afterpay

    : Timeout - Async callback was not invoked within the 100000 ms timeout specified by jest.setTimeout.Timeout - Async callback was not invoked within the 100000 ms timeout specified by jest.setTimeout.Error:

Additional context

I've looked into this a bit and haven't been able to determine why these are failing on GitHub but pass when running the shopper tests locally.

Priority

It would be great to get all of these e2e tests fixed so the results are meaningful again. I personally know that I didn't check the output of this test when my PR merged because they've been generally failing for so long. Leaving this up to the triage team.

Reason why this e2e test is broken

Important

Please, ensure when closing this issue (PR fix) that only one e2e: broken label is added and it is accurate.

  • I confirmed there's only one e2e: broken label in this issue and it is accurate.
@brettshumaker brettshumaker added type: bug The issue is a confirmed bug. category: e2e Issues and PRs related to e2e tests. needs triage Manually put issue into triage process. focus: checkout payments e2e: broken test e2e test itself is not working as expected. labels May 8, 2024
@brettshumaker brettshumaker changed the title Tests for Tests for BNPL checkouts failing. May 8, 2024
@pierorocca pierorocca added the priority: high The issue/PR is high priority—it affects lots of customers substantially, but not critically. label May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: e2e Issues and PRs related to e2e tests. e2e: broken test e2e test itself is not working as expected. focus: checkout payments needs triage Manually put issue into triage process. priority: high The issue/PR is high priority—it affects lots of customers substantially, but not critically. type: bug The issue is a confirmed bug.
Projects
None yet
Development

No branches or pull requests

2 participants