From cbe17b0ffff4e1a069be800446e1e696be585632 Mon Sep 17 00:00:00 2001 From: StylusFrost Date: Wed, 15 Oct 2025 16:12:57 +0200 Subject: [PATCH] test(ui): update GitHub sign-in button locator in E2E tests - Changed the locator for the GitHub sign-in button in the sign-up page tests to use the input type and value attributes for better accuracy. - This update enhances the reliability of the E2E tests by ensuring the correct element is targeted during the GitHub OAuth flow. --- ui/tests/sign-up/sign-up-page.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/tests/sign-up/sign-up-page.ts b/ui/tests/sign-up/sign-up-page.ts index e86b98dbf8..fce4b9871d 100644 --- a/ui/tests/sign-up/sign-up-page.ts +++ b/ui/tests/sign-up/sign-up-page.ts @@ -172,7 +172,7 @@ export class SignUpPage extends BasePage { async submitGithubLogin(): Promise { // Click Github Sign in button - await this.page.getByRole("button", { name: "Sign in" }).click(); + await this.page.locator('input[type="submit"][name="commit"][value="Sign in"]').click(); } async completeGithubOAuth(username: string, password: string): Promise { @@ -194,7 +194,7 @@ export class SignUpPage extends BasePage { // Verify GitHub OAuth form elements are present await expect(this.page.getByRole("textbox", { name: /username or email/i })).toBeVisible(); await expect(this.page.getByRole("textbox", { name: /password/i })).toBeVisible(); - await expect(this.page.getByRole("button", { name: "Sign in" })).toBeVisible(); + await expect(this.page.locator('input[type="submit"][name="commit"][value="Sign in"]')).toBeVisible(); } }