test(web): cover timeline and estimate fallback flows

This commit is contained in:
2026-03-30 14:37:10 +02:00
parent 8655cb5bfa
commit be6be64e3d
2 changed files with 76 additions and 21 deletions
+17
View File
@@ -46,6 +46,23 @@ test.describe("Timeline", () => {
await todayBtn.click();
});
test("keeps timeline data populated after navigating from allocations", async ({ page }) => {
await page.goto("/allocations");
await expect(
page.locator("h1").filter({ hasText: /Allocations|Planning/i }),
).toBeVisible({ timeout: 10000 });
await page.locator('nav a >> text="Timeline"').first().click();
await expect(page).toHaveURL(/\/timeline/);
await expect(
page.locator(".app-toolbar").getByText(/[1-9]\d* resources · [1-9]\d* allocations/),
).toBeVisible({ timeout: 10000 });
await expect(page.getByTestId("timeline-resource-row-canvas").first()).toBeVisible({
timeout: 10000,
});
await expect(page.locator("text=No allocations in this time range")).not.toBeVisible();
});
test("filter panel opens and closes", async ({ page }) => {
await page.locator("button", { hasText: "Filter" }).click();
await expect(page.getByRole("heading", { name: "Filters" })).toBeVisible();