seahaven-ap/e2e/sea-haven-brand.spec.ts

32 lines
1.3 KiB
TypeScript

import { expect, test } from "@playwright/test";
test.describe("Sea Haven brand module hide-list (AP-40)", () => {
test("hides unused modules, keeps reports, stubs remain, billing route gone", async ({
page,
}) => {
await page.goto("/");
await expect(page.getByTestId("app-wordmark")).toContainText("SEA HAVEN");
await expect(page.getByTestId("module-rail")).toBeVisible();
await expect(page.getByTestId("nav-procurement")).toHaveCount(0);
await expect(page.getByTestId("nav-past-invoices")).toHaveCount(0);
await expect(page.getByTestId("nav-recurring")).toHaveCount(0);
await expect(page.getByTestId("nav-billing")).toHaveCount(0);
await expect(page.getByTestId("nav-reports")).toBeVisible();
await expect(page.getByTestId("nav-invoice-processing")).toBeVisible();
await page.goto("/procurement");
await expect(page.getByTestId("procurement-page")).toBeVisible();
await page.goto("/past-invoices");
await expect(page.getByTestId("past-invoices-page")).toBeVisible();
await page.goto("/recurring");
await expect(page.getByTestId("recurring-page")).toBeVisible();
await page.goto("/billing");
await expect(page.getByTestId("billing-page")).toHaveCount(0);
await expect(page.getByTestId("module-rail")).toBeVisible();
});
});