mirror of
https://github.com/bitwarden/browser
synced 2026-02-10 05:30:01 +00:00
@@ -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(
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<!--
|
||||
<!--
|
||||
# Table of Contents
|
||||
|
||||
This file contains a single consolidated template for all visual clients.
|
||||
@@ -16,7 +16,6 @@
|
||||
<bit-form-field>
|
||||
<bit-label>{{ "emailAddress" | i18n }}</bit-label>
|
||||
<input
|
||||
id="login_input_email"
|
||||
type="email"
|
||||
formControlName="email"
|
||||
bitInput
|
||||
@@ -40,7 +39,6 @@
|
||||
<div class="tw-grid tw-gap-3">
|
||||
<!-- Continue button -->
|
||||
<button
|
||||
id="login_button_continue"
|
||||
type="button"
|
||||
bitButton
|
||||
block
|
||||
@@ -80,13 +78,7 @@
|
||||
<!-- Master Password input -->
|
||||
<bit-form-field class="!tw-mb-1">
|
||||
<bit-label>{{ "masterPass" | i18n }}</bit-label>
|
||||
<input
|
||||
id="login_input_password"
|
||||
type="password"
|
||||
formControlName="masterPassword"
|
||||
bitInput
|
||||
#masterPasswordInputRef
|
||||
/>
|
||||
<input type="password" formControlName="masterPassword" bitInput #masterPasswordInputRef />
|
||||
<button type="button" bitIconButton bitSuffix bitPasswordInputToggle></button>
|
||||
</bit-form-field>
|
||||
|
||||
@@ -97,14 +89,7 @@
|
||||
|
||||
<div class="tw-grid tw-gap-3">
|
||||
<!-- Submit button to Login with Master Password -->
|
||||
<button
|
||||
id="login_button_submit"
|
||||
type="submit"
|
||||
bitButton
|
||||
bitFormButton
|
||||
block
|
||||
buttonType="primary"
|
||||
>
|
||||
<button type="submit" bitButton bitFormButton block buttonType="primary">
|
||||
{{ "loginWithMasterPassword" | i18n }}
|
||||
</button>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user