mirror of https://github.com/OpenVidu/openvidu.git
1.3 KiB
1.3 KiB
End-to-end tests (@openvidu-dashboard/e2e)
- Playwright on Chromium against the production build served by
scripts/serve.mjs, which also strips a/dashboard/prefix for the base href test. The API is mocked byfixtures/api.ts(page.route()). - Suites include axe checks and light and dark baseline screenshots.
maxDiffPixelRatio0.01 lets small UI changes pass; regenerate with--update-snapshots=allwhen a change is intended. tests-backend/(playwright.backend.config.ts) runs the session flow against the real backend on a MongoDB seeded from the contract fixtures (scripts/serve-dashboard.mjs,scripts/seed-rooms.mjs);./dashboard.sh e2eruns it when Docker orDASHBOARD_TEST_MONGO_URIis available and reports it skipped otherwise.- The server and the fixtures are exported for the suites of extending applications (
@openvidu-dashboard/e2e/servewithE2E_APP_ROOT,@openvidu-dashboard/e2e/fixtures): theroutesoption ofMockApianswers the paths the CE mock does not know, andanalyticsadds series values and breakdown keys. To run the suite after a build:pnpm --filter @openvidu-dashboard/e2e run e2e [playwright args]. - Install the browser once:
pnpm --filter @openvidu-dashboard/e2e exec playwright install chromium.