Skip to content

Commit

Permalink
rename change selector
Browse files Browse the repository at this point in the history
  • Loading branch information
Seroxdesign committed Jan 25, 2024
1 parent fd70daa commit 55ff745
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
5 changes: 2 additions & 3 deletions wallets/metamask/src/pages/HomePage/actions/renameAccount.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@ export async function renameAccount(page: Page, newAccountName: Account['name'])
await page.locator(Selectors.accountMenu.accountButton).click()

await page.locator(Selectors.accountMenu.renameAccountMenu.listItemButton).click()
await page.locator(Selectors.accountMenu.renameAccountMenu.listItemDetails).click()
await page.locator(Selectors.accountMenu.renameAccountMenu.listItemDetailButton).click()
await page.locator(Selectors.accountMenu.renameAccountMenu.renameButton).click()
await page.locator(Selectors.accountMenu.renameAccountMenu.renameInput).fill(newAccountName)

await page.locator(Selectors.accountMenu.renameAccountMenu.renameConfirmButton).click()
await page.keyboard.press('Enter')
}
7 changes: 3 additions & 4 deletions wallets/metamask/src/pages/HomePage/selectors/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,9 @@ const addNewAccountMenu = {

const renameAccountMenu = {
listItemButton: `${accountMenuContainer} ${createDataTestSelector('account-list-item-menu-button')}`,
listItemDetails: `${accountMenuContainer} ${createDataTestSelector('account-list-menu-details')}`,
renameButton: `${accountMenuContainer} ${createDataTestSelector('editable-label-button')}`,
renameInput: `${accountMenuContainer} input`,
renameConfirmButton: `${accountMenuContainer} button.mm-button-icon`,
listItemDetailButton: `${createDataTestSelector('account-list-menu-details')}`,
renameButton: `${createDataTestSelector('editable-label-button')}`,
renameInput: `input`,
}

const importAccountMenu = {
Expand Down

0 comments on commit 55ff745

Please sign in to comment.