Closed chanon closed 5 months ago
Tested this on Github Codespaces and it works fine there. Does vitest --pool=forks
make this work better on Windows?
Aha! yes. That works. I somehow missed that in the docs.
The uWebSockets.js
seems to be native node addon. Those have some compatibility issues with Vitest's default pool. In the next major we'll be defaulting to pool: 'forks'
so that this kind of issues would not come up: https://github.com/vitest-dev/vitest/pull/5047
Describe the bug
Just calling uwebsocket's
App()
will terminate the test and Vitest will not show results of any tests.I have tried looking through the Vitest documentation to see what the problem could be, but did not find anything.
Reproduction
Complete minimal reproduction in github repo: https://github.com/chanon/vitest-uws/
The test code in
tests/minimal.test.ts
:Run
Result:
Comment
App()
call and run again.Result:
System Info
Used Package Manager
pnpm
Validations