fix(e2e): scope Create button locator to message-input-root

The unscoped getByRole("button", { name: "Create" }) matched sidebar
"Create a new workspace" buttons from other test suites. Scoping to
message-input-root targets only the Composer submit button.
This commit is contained in:
Mohamed Boudra
2026-04-14 12:07:57 +07:00
parent d888da8591
commit 4d6774f0c2
+3 -1
View File
@@ -169,7 +169,9 @@ export async function clickNewWorkspaceButton(
timeout: 30_000,
});
const createButton = page.getByRole("button", { name: "Create" });
const createButton = page
.getByTestId("message-input-root")
.getByRole("button", { name: "Create" });
await expect(createButton).toBeVisible({ timeout: 30_000 });
await createButton.click();
}