You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When developing tools atop of vitest using the programmatic API, tools, like mutation testing frameworks (i.e. StrykerJS), sometimes need to report additional data from the testing environment back to the main process.
constvitest=awaitcreateVitest("test",{watch: false});vitest.projects[0].config.setupFiles=["vitest.setup.js"];awaitvitest.start();vitest.state.getFiles()[0].result.meta.custom// per suite/worker we can get the custom data here
The vitest-plugin in StrykerJS currently uses files to communicate between the test environment and the main process. This works, but doesn't support "Browser mode".
Clear and concise description of the problem
When developing tools atop of vitest using the programmatic API, tools, like mutation testing frameworks (i.e. StrykerJS), sometimes need to report additional data from the testing environment back to the main process.
See #3017 (reply in thread)
Suggested solution
Using a custom
vitest.setup.js
A tool could use this:
Alternative
An
rpc
approach is also mentioned here: #3017 (reply in thread)Additional context
The vitest-plugin in StrykerJS currently uses files to communicate between the test environment and the main process. This works, but doesn't support "Browser mode".
Validations
The text was updated successfully, but these errors were encountered: