-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
feat: uiVitest UIVitest UI
Description
Describe the bug
When trying to log out HTML text in the console log with vitest UI, vitest UI is cutting up the output a lot, missing entire tags and symbols.
This is what the exact same output looks like in my terminal:

vitest UI seems to be removing all lines starting with < so entire lines like <body> are missing in the output.
This makes it extremely hard to debug anything to do with HTML when using vitest UI and I have to revert to using my console every time.
As a React developer who uses @testing-library/react and screen.debug() a lot. I am constantly looking at HTML output in my tests.
Reproduction
Try to console log any HTML in a test with vitest UI.
Or use React testing library's screen.debug method in any component to see the broken output.
System Info
System:
OS: macOS 12.3.1
CPU: (10) arm64 Apple M1 Max
Memory: 3.49 GB / 32.00 GB
Shell: 5.8 - /bin/zsh
Binaries:
Node: 18.0.0 - /usr/local/bin/node
Yarn: 1.22.17 - /usr/local/bin/yarn
npm: 8.6.0 - /usr/local/bin/npm
Browsers:
Brave Browser: 101.1.38.111
Chrome: 101.0.4951.54
Firefox: 99.0.1
Safari: 15.4
npmPackages:
@vitejs/plugin-react: 1.3.2 => 1.3.2
vite: 2.9.8 => 2.9.8
vitest: ^0.12.1 => 0.12.1Used Package Manager
pnpm
Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
- The provided reproduction is a minimal reproducible example of the bug.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
feat: uiVitest UIVitest UI
