Deep DivesAdmin
Testing
Testing guide for the RawStack Admin component.
The Admin has two main levels of testing. As a general rule, Vitest should cover components, hooks, and utilities, while Playwright should cover complete browser-based user flows through the application.
Unit tests
Component and utility tests run with Vitest.
npm run test
npm run test:run
npm run test:uiE2E tests
Playwright runs the Admin in a real browser and exercises complete flows through the interface.
npm run test:e2eEnsure the Vite dev server and API are both running before executing end-to-end tests.
Coverage
To generate a coverage report from the Vitest suite:
npm run test:run -- --coverage