diff --git a/playwright/PageObjects/CreateOrImport.ts b/playwright/PageObjects/CreateOrImport.ts index 509e0a0..54b02cf 100644 --- a/playwright/PageObjects/CreateOrImport.ts +++ b/playwright/PageObjects/CreateOrImport.ts @@ -3,14 +3,12 @@ import { type Locator, type Page } from "@playwright/test"; export class CreateOrImportPage extends MainPage { readonly buttonCreateAccount: Locator; - readonly buttonImportAccount: Locator; readonly labelCreateTitle: Locator; readonly textCreateDescription: Locator; constructor(public readonly page: Page) { super(page); this.buttonCreateAccount = this.page.getByTestId("button-create-account"); - this.buttonImportAccount = this.page.getByTestId("button-import-account"); this.labelCreateTitle = this.page.getByTestId("label-create-title"); this.textCreateDescription = this.page.getByTestId( "text-create-description", diff --git a/playwright/PageObjects/LoginPin.ts b/playwright/PageObjects/LoginPin.ts index 9b9afeb..ffb2c50 100644 --- a/playwright/PageObjects/LoginPin.ts +++ b/playwright/PageObjects/LoginPin.ts @@ -2,7 +2,6 @@ import MainPage from "./MainPage"; import { expect, type Locator, type Page } from "@playwright/test"; export class LoginPinPage extends MainPage { - readonly buttonChangeUser: Locator; readonly buttonClearInput: Locator; readonly buttonCreateNewProfile: Locator; readonly buttonPinSettings: Locator; @@ -25,18 +24,12 @@ export class LoginPinPage extends MainPage { readonly scrambleKeypadCheckbox: Locator; readonly scrambleKeypadLabel: Locator; readonly scrambleKeypadSwitch: Locator; - readonly selectProfileLabel: Locator; - readonly selectProfileUser: Locator; - readonly selectProfileUserImage: Locator; - readonly selectProfileUserName: Locator; - readonly selectProfileModal: Locator; readonly stayUnlockedCheckbox: Locator; readonly stayUnlockedLabel: Locator; readonly stayUnlockedSwitch: Locator; constructor(public readonly page: Page) { super(page); - this.buttonChangeUser = this.page.getByTestId("button-change-user"); this.buttonClearInput = this.page.getByTestId("button-clear-input"); this.buttonCreateNewProfile = this.page.getByTestId( "button-create-new-profile", @@ -61,15 +54,6 @@ export class LoginPinPage extends MainPage { this.scrambleKeypadCheckbox = this.page.locator(".slider").first(); this.scrambleKeypadLabel = this.page.getByTestId("label-scramble-keypad"); this.scrambleKeypadSwitch = this.page.getByTestId("switch-scramble-keypad"); - this.selectProfileLabel = this.page.getByTestId("label-select-profile"); - this.selectProfileUser = this.page.getByTestId("select-profile-user"); - this.selectProfileUserImage = this.page.getByTestId( - "select-profile-user-image", - ); - this.selectProfileUserName = this.page.getByTestId( - "select-profile-user-name", - ); - this.selectProfileModal = this.page.getByTestId("modal-select-profile"); this.stayUnlockedCheckbox = this.page.locator(".slider").last(); this.stayUnlockedLabel = this.page.getByTestId("label-stay-unlocked"); this.stayUnlockedSwitch = this.page.getByTestId("switch-stay-unlocked"); diff --git a/playwright/specs/01-pin-input.spec.ts b/playwright/specs/01-pin-input.spec.ts index f19edcc..a08618c 100644 --- a/playwright/specs/01-pin-input.spec.ts +++ b/playwright/specs/01-pin-input.spec.ts @@ -33,9 +33,6 @@ test.describe("Create Account and Login Tests", () => { await expect(createOrImport.buttonCreateAccount).toHaveText( "Create New Account", ); - await expect(createOrImport.buttonImportAccount).toHaveText( - "Import Account", - ); await createOrImport.clickCreateNewAccount(); // Validate Create New User/Status page, enter valid data and continue @@ -256,36 +253,6 @@ test.describe("Create Account and Login Tests", () => { await page.waitForURL("/chat"); }); - test("A10 - User can see menu to switch to a different profile", async ({ - enterPinUserContext, - }) => { - const page = enterPinUserContext.page; - const createOrImport = new CreateOrImportPage(page); - const authNewAccount = new AuthNewAccount(page); - const loginPinPage = new LoginPinPage(page); - - // Click on Create New Account - await createOrImport.clickCreateNewAccount(); - - // Enter Username and Status - await authNewAccount.validateLoadingHeader(); - await authNewAccount.typeOnUsername(username); - await authNewAccount.typeOnStatus(status); - await authNewAccount.buttonNewAccountCreate.click(); - - // Login Page Test - await loginPinPage.waitUntilPageIsLoaded(); - await loginPinPage.buttonChangeUser.click(); - await expect(loginPinPage.selectProfileModal).toBeVisible(); - await expect(loginPinPage.selectProfileLabel).toHaveText("Profiles"); - await expect(loginPinPage.selectProfileUserName.first()).toHaveText( - "Space Kev", - ); - await expect(loginPinPage.selectProfileUserName.last()).toHaveText( - "Sara Saturn", - ); - }); - test("A12 - If incorrect pin is entered, error message should be displayed", async ({ enterPinUserContext, }) => {