diff --git a/e2e/work-orders/pending-status-menu.spec.ts b/e2e/work-orders/pending-status-menu.spec.ts index 90c1beca..8988c8b5 100644 --- a/e2e/work-orders/pending-status-menu.spec.ts +++ b/e2e/work-orders/pending-status-menu.spec.ts @@ -169,7 +169,9 @@ test.describe("existing work order status menu", () => { const menu = page.locator(".MuiPopover-paper").last(); await expect(menu.getByRole("button", { name: "Pending", exact: true })).toBeEnabled(); await menu.getByRole("button", { name: "Pending", exact: true }).click(); - await expect(page.getByRole("button", { name: "Pending", exact: true })).toBeVisible(); + await expect( + page.getByRole("dialog").getByRole("button", { name: "Pending", exact: true }), + ).toBeVisible(); await page.getByRole("button", { name: "Create work order" }).click(); await expect(page.getByRole("heading", { name: "Type & schedule" })).toBeHidden();