diff --git a/apps/web/src/app/auth/login/example.play.spec.ts b/apps/web/src/app/auth/login/example.play.spec.ts index 3f8c6fe1ac4..8fa00804d11 100644 --- a/apps/web/src/app/auth/login/example.play.spec.ts +++ b/apps/web/src/app/auth/login/example.play.spec.ts @@ -5,14 +5,17 @@ import { Play, SingleUserRecipe } from "@bitwarden/playwright-helpers"; test("login with password", async ({ page }) => { using scene = await Play.scene(new SingleUserRecipe({ email: "test@example.com" })); - await page.goto("/#/login"); - - await page.locator("#login_input_email").fill(scene.mangle("test@example.com")); - await page.locator("#login_button_continue").click(); - - await page.locator("#login_input_password").fill("asdfasdfasdf"); - await page.locator("#login_button_submit").click(); - + await page.goto("https://localhost:8080/#/login"); + await page.getByRole("textbox", { name: "Email address (required)" }).click(); + await page + .getByRole("textbox", { name: "Email address (required)" }) + .fill(scene.mangle("test@example.com")); + await page.getByRole("textbox", { name: "Email address (required)" }).press("Enter"); + await page.getByRole("textbox", { name: "Master password (required)" }).click(); + await page + .getByRole("textbox", { name: "Master password (required)" }) + .fill(scene.mangle("asdfasdfasdf")); + await page.getByRole("button", { name: "Log in with master password" }).click(); await expect(page.getByRole("button", { name: "Add it later" })).toBeVisible(); await page.getByRole("button", { name: "Add it later" }).click(); await expect(page.locator("bit-simple-dialog")).toContainText( diff --git a/libs/auth/src/angular/login/login.component.html b/libs/auth/src/angular/login/login.component.html index ca436fb034f..26e19f11147 100644 --- a/libs/auth/src/angular/login/login.component.html +++ b/libs/auth/src/angular/login/login.component.html @@ -1,4 +1,4 @@ - @@ -97,14 +89,7 @@
-