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 request: Code coverage of tests running miniflare #140

Closed
vlovich opened this issue Jan 2, 2022 · 1 comment
Closed

Feature request: Code coverage of tests running miniflare #140

vlovich opened this issue Jan 2, 2022 · 1 comment
Labels
dependency Issue in dependency

Comments

@vlovich
Copy link
Contributor

vlovich commented Jan 2, 2022

Currently, my code is launching Miniflare manually & making requests against it and testing that. However, adding --coverage to jest doesn't capture this. I'm assuming this is because it's running in a separate process. Not sure what kind of integration would be needed but this would be pretty neat to fix (not super critical, but a nice-to-have).

@mrbbot
Copy link
Contributor

mrbbot commented Jan 2, 2022

Hey! 👋 I think this might be a Jest issue. Looks like it currently excludes files executed by the vm module from coverage. However, using c8 instead seems to work:

NODE_OPTIONS=--experimental-vm-modules npx c8 jest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependency Issue in dependency
Projects
None yet
Development

No branches or pull requests

2 participants