Files
Dash/frontend/e2e/smoke.spec.ts
T
Tomas Dvorak 17a579880f refactor(frontend): restructure project layout and update API schema
Relocate frontend source code from `next-app/` to `frontend/` to align with the new project structure. This includes removing the old Next.js boilerplate files and establishing a cleaner workspace.

Additionally, updates the OpenAPI specification to include support for the `immich` widget type and its corresponding configuration schema.

- Move frontend files to `frontend/`
- Delete obsolete `next-app/` directory and its configuration
- Add `immich` widget type to `openapi.yaml`
- Update `FrontendPlan.md` with dashboard refactor and UX direction
2026-05-04 12:31:34 +02:00

26 lines
965 B
TypeScript

import { test, expect } from "@playwright/test";
test("smoke: page loads with header", async ({ page }) => {
await page.goto("http://localhost:3000");
await expect(page.locator("header")).toBeVisible();
await expect(page.getByText("Dash")).toBeVisible();
});
test("smoke: theme toggle works", async ({ page }) => {
await page.goto("http://localhost:3000");
const toggle = page.getByLabel("Toggle theme");
await toggle.click();
await page.getByText("CasaOS").click();
const theme = await page.evaluate(() => document.documentElement.getAttribute("data-theme"));
expect(theme).toBe("casaos");
});
test("smoke: empty state shows add button", async ({ page }) => {
await page.goto("http://localhost:3000");
// If no services exist, the empty state should be visible
const emptyState = page.getByText("No apps yet");
if (await emptyState.isVisible()) {
await expect(page.getByRole("button", { name: /add app/i })).toBeVisible();
}
});