feat: add Playwright E2E testing setup with POM and testids

- Install @playwright/test and Chromium browser
- Create playwright.config.ts with dev server integration
- Add data-testid attributes to LoginPage, DashboardPage, ServerCard, Sidebar
- Exclude tests-e2e from vitest config
- Create Page Object Models: LoginPage, DashboardPage
- Add 18 E2E tests: 6 login flow, 12 dashboard (happy, empty, error states)
- Add test:e2e and test:e2e:ui scripts to package.json
This commit is contained in:
Tran G. (Revernomad) Khoa
2026-04-17 00:01:11 +07:00
parent 88424675b5
commit 620429c9b8
12 changed files with 471 additions and 11 deletions

View File

@@ -14,5 +14,6 @@ export default defineConfig({
environment: "jsdom",
setupFiles: ["./src/__tests__/setup.ts"],
css: true,
exclude: ["node_modules", "tests-e2e", "**/tests-e2e/**"],
},
});