Error code of test run with not default reporter always 0 even with unhandled error #6831
Closed
6 tasks done
Labels
p3-minor-bug
An edge case that only affects very specific usage (priority)
Describe the bug
When you have in the list of reporters any other than
basic
reporters, the vitest process always exits with a 0 status code. If you have the default or the basic reporter process exit, in case of an unhandled error, with status code 1.Reproduction
https://stackblitz.com/edit/vitest-dev-vitest-5r9pk4
npm run test:run
— everything okay, we see error andecho $?
gives us 1CI=1 npm run test:run
— not okay: we don't see error andecho $?
gives us 0System Info
Used Package Manager
npm
Validations
The text was updated successfully, but these errors were encountered: