mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-05-13 17:52:38 +02:00
test(web): add Playwright config and dashboard smoke test
This commit is contained in:
parent
c3614f7a3e
commit
876f1da020
3 changed files with 143 additions and 0 deletions
21
surfsense_web/tests/dashboard.spec.ts
Normal file
21
surfsense_web/tests/dashboard.spec.ts
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
import { expect, test } from "@playwright/test";
|
||||
|
||||
/**
|
||||
* Tracer-bullet test: proves the entire E2E pipeline works end-to-end.
|
||||
*
|
||||
* Verifies:
|
||||
* - Web server is reachable
|
||||
* - Auth setup ran successfully (storageState contains valid token)
|
||||
* - Dashboard route renders for an authenticated user
|
||||
*
|
||||
* Keep this test minimal. Product-specific behaviour belongs in dedicated
|
||||
* spec files (new-chat, search-spaces, editor-panel, etc.).
|
||||
*/
|
||||
test.describe("Dashboard", () => {
|
||||
test("loads dashboard with sidebar navigation for authenticated user", async ({ page }) => {
|
||||
await page.goto("/dashboard");
|
||||
|
||||
await expect(page).toHaveURL(/\/dashboard/);
|
||||
await expect(page.getByRole("navigation").first()).toBeVisible();
|
||||
});
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue