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

[With test] Function loadStripe() does not work #1685

Open
Spixmaster opened this issue Jan 11, 2025 · 0 comments
Open

[With test] Function loadStripe() does not work #1685

Spixmaster opened this issue Jan 11, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@Spixmaster
Copy link

Spixmaster commented Jan 11, 2025

Version: 16.5.3

Source code:

happy-dom is pre-loaded as per instruction.

import {
    loadStripe,
    type Stripe
} from "@stripe/stripe-js";
import {assert} from "assert-ts";

test("showcase", async (): Promise<undefined> =>
{
    const stripe: null | Stripe = await loadStripe("some-public-key");
    assert(stripe !== null);
});

Result:

❯ bun test --coverage tests/src-web/typescript/payment.test.ts
bun test v1.1.42 (50eec002)

error: Test "showcase" timed out after 5002ms
✗ showcase [5002.48ms]

Increasing the timeout does not help. The function loadStripe() takes forever.

Expected:
The function loadStripe() should finish. The source code works in the browser.

@Spixmaster Spixmaster added the bug Something isn't working label Jan 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant