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
After following the instructions, pulling the reproduction repo, and otherwise trying to get a basic installation of Vitest + Playwright + Nuxt working, I've found that I can't.
Logs
The text was updated successfully, but these errors were encountered:
The documentation around Browser Testing is super confusing. I finally figured out that Nuxt supports Playwright via Vitest but ONLY in the Node context and that it's a complete replacement for Vitest's own Playwright stuff.
The Nuxt documentation as written is NOT supposed to be used with Vitest's Playwright as Vitest documents it and that they're completely unrelated aside from Vitest being the test runner.
😭
I was so confused about which page I was dealing with and the interoperability between Vitests Page API and Nuxt's Page API. It was mainly the TypeScript and expect types that were throwing me off.
I expected Vitest's expect to have been extended with DOM matchers and it wasn't. Now I understand why.
This issue is still applicable because I still want to render my Nuxt app in Vitest browser mode, but I am a little less confused about the purpose of @nuxt/test-utils/e2e.
@danielroe sorry for tagging you directly but I think that you can help us here. As @JessicaSachs mentioned, there is A LOT of confusion around tests in nuxt/vitetest/vue/playwright...
I think that the current documentations needs to be more clear, maybe we need more examples? More use cases? I don't know but I want to start a discussion around this and improve the DX for others.
Environment
Darwin
v22.9.0
3.15.4
3.21.1
2.10.4
pnpm@9.6.0
-
compatibilityDate
,devtools
-
-
Reproduction
https://github.com/JessicaSachs/nuxt-playwright-vitest-browser-repro
Describe the bug
Vitest completely hangs when I try to launch it with
pnpm vitest
There's an error in the Vitest browser UI which is swallowed by the CLI
❯ /node_modules/.pnpm/vite@6.0.11_@types+node@22.12.0_jiti@2.4.2_terser@5.37.0_yaml@2.7.0/node_modules/vite/dist/client/env.mjs:12:482
Additional context
After following the instructions, pulling the reproduction repo, and otherwise trying to get a basic installation of Vitest + Playwright + Nuxt working, I've found that I can't.
Logs
The text was updated successfully, but these errors were encountered: