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
CI=true bun run test --ui
bun run preview --outDir html
Also it would be nice to have iframe url somehow obtained from coverage.reportsDirectory, for example if coverage.reportsDirectory is located under <rootDir>/html (vitest html reporter root dir), then relative url is calculated.
akcyp
changed the title
vitest/ui html generated html report have invalid iframe url to coverage page
vitest/ui coverage page have invalid iframe url when running on preview mode (pre-generated report)
Sep 19, 2023
I'm having the same problem as you.
When executing vitest --ui, the port of vitest ui != the port of iframe, after I corrected the iframe port in F12, it can be displayed, but I don't know how to fix it in setting.
Describe the bug
UI converage page works well in "test development mode", but fails to load on generated report (after running
vite preview --outDir html
).Root cause: https://github.com/vitest-dev/vitest/blob/main/packages/ui/client/composables/navigation.ts#L22
Another minor issue:
CI=true vitest --ui
should not open browserReproduction
CI=true bun run test --ui bun run preview --outDir html
Also it would be nice to have iframe url somehow obtained from
coverage.reportsDirectory
, for example ifcoverage.reportsDirectory
is located under<rootDir>/html
(vitest html reporter root dir), then relative url is calculated.System Info
Used Package Manager
bun
Validations
The text was updated successfully, but these errors were encountered: