-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
discussionp2-nice-to-haveNot breaking anything but nice to have (priority)Not breaking anything but nice to have (priority)
Description
Clear and concise description of the problem
Currently, if a test fails, I see the error a total of 3 times, one time being a complete serialized representation of the error.
The most problematic of these is the serialized error.
In my use-case, I happen to be using Zod who's Error objects can be very large.
When every test run output ends with a serialized representation of a Zod error, I end up having to scroll up a page or more until I can see the normal vitest output.
This is what the output looks like for me:

Suggested solution
Would it make sense to have a flag making the output less noisy?
This seems to be the offending line:
vitest/packages/vitest/src/node/error.ts
Line 206 in 18d8019
| logger.error(c.red(c.bold('Serialized Error:')), c.gray(propertiesString)) |
Alternative
No response
Additional context
No response
Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
discussionp2-nice-to-haveNot breaking anything but nice to have (priority)Not breaking anything but nice to have (priority)
Type
Projects
Status
Has plan