mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
await
all clicks during e2e tests (#7815)
The `.click()` function returns a Promise, as it needs to communicate with the browser and ensure the click was successfully sent.
This commit is contained in:
parent
a891fa36b6
commit
f7aea9597b
@ -56,19 +56,19 @@ describe('MetaMask', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Create New Wallet" option', async () => {
|
it('clicks the "Create New Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -161,7 +161,7 @@ describe('MetaMask', function () {
|
|||||||
await passwordInputs[0].sendKeys('correct horse battery staple')
|
await passwordInputs[0].sendKeys('correct horse battery staple')
|
||||||
await passwordInputs[1].sendKeys('correct horse battery staple')
|
await passwordInputs[1].sendKeys('correct horse battery staple')
|
||||||
const restoreButton = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.restore.message}')]`))
|
const restoreButton = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.restore.message}')]`))
|
||||||
restoreButton.click()
|
await restoreButton.click()
|
||||||
await driver.delay(regularDelayMs)
|
await driver.delay(regularDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -55,19 +55,19 @@ describe('MetaMask', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Create New Wallet" option', async () => {
|
it('clicks the "Create New Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -60,19 +60,19 @@ describe('Using MetaMask with an existing account', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Import Wallet" option', async () => {
|
it('clicks the "Import Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -60,19 +60,19 @@ describe('MetaMask', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Create New Wallet" option', async () => {
|
it('clicks the "Create New Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -50,19 +50,19 @@ describe('MetaMask', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Create New Wallet" option', async () => {
|
it('clicks the "Create New Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "I agree" option on the metametrics opt-in screen', async () => {
|
it('clicks the "I agree" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-primary'))
|
const optOutButton = await driver.findElement(By.css('.btn-primary'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -51,19 +51,19 @@ describe('MetaMask', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Create New Wallet" option', async () => {
|
it('clicks the "Create New Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -196,7 +196,7 @@ describe('MetaMask', function () {
|
|||||||
describe('Import seed phrase', () => {
|
describe('Import seed phrase', () => {
|
||||||
it('logs out of the vault', async () => {
|
it('logs out of the vault', async () => {
|
||||||
const accountMenuButton = await driver.findElement(By.css('.account-menu__icon'))
|
const accountMenuButton = await driver.findElement(By.css('.account-menu__icon'))
|
||||||
accountMenuButton.click()
|
await accountMenuButton.click()
|
||||||
await driver.delay(regularDelayMs)
|
await driver.delay(regularDelayMs)
|
||||||
|
|
||||||
const logoutButton = await driver.findElement(By.css('.account-menu__logout-button'))
|
const logoutButton = await driver.findElement(By.css('.account-menu__logout-button'))
|
||||||
@ -406,7 +406,7 @@ describe('MetaMask', function () {
|
|||||||
await driver.delay(regularDelayMs)
|
await driver.delay(regularDelayMs)
|
||||||
|
|
||||||
const settingsButton = await driver.findElement(By.xpath(`//div[contains(text(), 'Settings')]`))
|
const settingsButton = await driver.findElement(By.xpath(`//div[contains(text(), 'Settings')]`))
|
||||||
settingsButton.click()
|
await settingsButton.click()
|
||||||
|
|
||||||
// await driver.findElement(By.css('.tab-bar'))
|
// await driver.findElement(By.css('.tab-bar'))
|
||||||
|
|
||||||
@ -989,7 +989,7 @@ describe('MetaMask', function () {
|
|||||||
assert(confirmDataText.match(/0xa9059cbb0000000000000000000000002f318c334780961fb129d2a6c30d0763d9a5c97/))
|
assert(confirmDataText.match(/0xa9059cbb0000000000000000000000002f318c334780961fb129d2a6c30d0763d9a5c97/))
|
||||||
|
|
||||||
const detailsTab = await driver.findElement(By.xpath(`//li[contains(text(), 'Details')]`))
|
const detailsTab = await driver.findElement(By.xpath(`//li[contains(text(), 'Details')]`))
|
||||||
detailsTab.click()
|
await detailsTab.click()
|
||||||
await driver.delay(regularDelayMs)
|
await driver.delay(regularDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -55,19 +55,19 @@ describe('MetaMask', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Create New Wallet" option', async () => {
|
it('clicks the "Create New Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Create a Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -57,19 +57,19 @@ describe('Using MetaMask with an existing account', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Import Wallet" option', async () => {
|
it('clicks the "Import Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -60,19 +60,19 @@ describe('MetaMask', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Import Wallet" option', async () => {
|
it('clicks the "Import Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -115,7 +115,7 @@ describe('MetaMask', function () {
|
|||||||
await driver.delay(regularDelayMs)
|
await driver.delay(regularDelayMs)
|
||||||
|
|
||||||
const settingsButton = await driver.findElement(By.xpath(`//div[contains(text(), 'Settings')]`))
|
const settingsButton = await driver.findElement(By.xpath(`//div[contains(text(), 'Settings')]`))
|
||||||
settingsButton.click()
|
await settingsButton.click()
|
||||||
})
|
})
|
||||||
|
|
||||||
it('turns on threebox syncing', async () => {
|
it('turns on threebox syncing', async () => {
|
||||||
@ -183,19 +183,19 @@ describe('MetaMask', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver2.findElement(By.css('.welcome-page__header'))
|
await driver2.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver2.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver2.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver2.delay(largeDelayMs)
|
await driver2.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Import Wallet" option', async () => {
|
it('clicks the "Import Wallet" option', async () => {
|
||||||
const customRpcButton = await driver2.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
const customRpcButton = await driver2.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver2.delay(largeDelayMs)
|
await driver2.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver2.findElement(By.css('.btn-default'))
|
const optOutButton = await driver2.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver2.delay(largeDelayMs)
|
await driver2.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -244,7 +244,7 @@ describe('MetaMask', function () {
|
|||||||
await driver.delay(regularDelayMs)
|
await driver.delay(regularDelayMs)
|
||||||
|
|
||||||
const settingsButton = await driver.findElement(By.xpath(`//div[contains(text(), 'Settings')]`))
|
const settingsButton = await driver.findElement(By.xpath(`//div[contains(text(), 'Settings')]`))
|
||||||
settingsButton.click()
|
await settingsButton.click()
|
||||||
})
|
})
|
||||||
|
|
||||||
it('finds the blockies toggle turned on', async () => {
|
it('finds the blockies toggle turned on', async () => {
|
||||||
|
@ -56,19 +56,19 @@ describe('Using MetaMask with an existing account', function () {
|
|||||||
it('clicks the continue button on the welcome screen', async () => {
|
it('clicks the continue button on the welcome screen', async () => {
|
||||||
await driver.findElement(By.css('.welcome-page__header'))
|
await driver.findElement(By.css('.welcome-page__header'))
|
||||||
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
const welcomeScreenBtn = await driver.findElement(By.xpath(`//button[contains(text(), '${enLocaleMessages.getStarted.message}')]`))
|
||||||
welcomeScreenBtn.click()
|
await welcomeScreenBtn.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "Import Wallet" option', async () => {
|
it('clicks the "Import Wallet" option', async () => {
|
||||||
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
const customRpcButton = await driver.findElement(By.xpath(`//button[contains(text(), 'Import Wallet')]`))
|
||||||
customRpcButton.click()
|
await customRpcButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
it('clicks the "No thanks" option on the metametrics opt-in screen', async () => {
|
||||||
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
const optOutButton = await driver.findElement(By.css('.btn-default'))
|
||||||
optOutButton.click()
|
await optOutButton.click()
|
||||||
await driver.delay(largeDelayMs)
|
await driver.delay(largeDelayMs)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user