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
LayZeeDK
changed the title
vitest: Vitest Browser doesn't keep the browser open
[@nx/vitest] Vitest Browser doesn't keep the browser open
Mar 4, 2025
LayZeeDK
changed the title
[@nx/vitest] Vitest Browser doesn't keep the browser open
[@nx/vite] Vitest Browser doesn't keep the browser open
Mar 4, 2025
Current Behavior
Expected Behavior
GitHub Repo
https://github.com/LayZeeDK/nx20-4-angular19-2-vitest-browser-playwright
Steps to Reproduce
Sample repo:
npm install
npm test
New workspace:
create-nx-workspace nx20-4-angular19-2-vitest-browser-playwright --framework=angular --app-name=angular-app --e2e-test-runner=playwright --unit-test-runner=vitest
apps/angular-app/vite.config.mts
nx test angular-app --ui
Nx Report
Failure Logs
Package Manager Version
No response
Operating System
Additional Information
I also tried Vite 6, Vitest 2, and Vitest 3 with Nx 20.4 and
20.5.0-rc.1
. I have triedtest.watch: true
invite.config.mts
.However, it works as expected when running
npx vitest --watch --ui
.This non-Nx Angular CLI workspace works when Vite is configured as described in the New workspace instructions: https://github.com/lacolaco/angular-vitest-sandbox
It uses Angular 18, Analog 1.5, Vite 5.3, and Vitest 1.6. It works both with WebdriverIO and Playwright. It works with both Angular
TestBed
and@testing-library/angular
. It is set up similar to what is described in https://dev.to/brandontroberts/faster-testing-with-angular-and-vitest-274n.The text was updated successfully, but these errors were encountered: