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: allow testing browser code in node #14019

Closed
wants to merge 5 commits into from
Closed

fix: allow testing browser code in node #14019

wants to merge 5 commits into from

Conversation

benmccann
Copy link
Member

@benmccann benmccann commented Oct 29, 2024

closes #13961

I tested this with the test project in that issue courtesy of our new pkg-pr-new setup and the tests passed

Copy link

changeset-bot bot commented Oct 29, 2024

🦋 Changeset detected

Latest commit: 29b0141

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
svelte Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@benmccann benmccann force-pushed the browser-node branch 3 times, most recently from e4431e0 to 47ae3ab Compare October 29, 2024 16:38
Copy link

pkg-pr-new bot commented Oct 29, 2024

pnpm add https://pkg.pr.new/svelte@14019

commit: 29b0141

Copy link

pkg-pr-new bot commented Oct 29, 2024

pnpm add https://pkg.pr.new/svelte@14019

commit: 2a666ad

@dominikg
Copy link
Member

wouldn't this prevent component testing wirh jsdom and a raf mock?

i don't understand why we use these conditions instead of a simple one-time check if requestAnimationFrame exists as a global at runtime initialization.

@benmccann
Copy link
Member Author

it wouldn't, but I was just about to close this with what I think is a simpler solution

@benmccann benmccann closed this Oct 29, 2024
@benmccann benmccann deleted the browser-node branch October 29, 2024 23:27
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.

SvelteSet does not behave correctly in Vitest
2 participants