diff options
author | Dan Miller <danjm.com@gmail.com> | 2018-08-15 03:15:07 +0800 |
---|---|---|
committer | Dan Miller <danjm.com@gmail.com> | 2018-08-15 03:15:07 +0800 |
commit | c4fe6aa9cfeddab231587359ef55ad80aa13efa0 (patch) | |
tree | 907d3fac3decbbbde0f50b705a9423882984f53f /test | |
parent | 42256cfbd2d2acb709981e6bdb9718163b6a3270 (diff) | |
download | tangerine-wallet-browser-c4fe6aa9cfeddab231587359ef55ad80aa13efa0.tar tangerine-wallet-browser-c4fe6aa9cfeddab231587359ef55ad80aa13efa0.tar.gz tangerine-wallet-browser-c4fe6aa9cfeddab231587359ef55ad80aa13efa0.tar.bz2 tangerine-wallet-browser-c4fe6aa9cfeddab231587359ef55ad80aa13efa0.tar.lz tangerine-wallet-browser-c4fe6aa9cfeddab231587359ef55ad80aa13efa0.tar.xz tangerine-wallet-browser-c4fe6aa9cfeddab231587359ef55ad80aa13efa0.tar.zst tangerine-wallet-browser-c4fe6aa9cfeddab231587359ef55ad80aa13efa0.zip |
Reload e2e beta test browser if initial screen doesn't load.
Diffstat (limited to 'test')
-rw-r--r-- | test/e2e/beta/from-import-beta-ui.spec.js | 9 | ||||
-rw-r--r-- | test/e2e/beta/metamask-beta-ui.spec.js | 9 |
2 files changed, 16 insertions, 2 deletions
diff --git a/test/e2e/beta/from-import-beta-ui.spec.js b/test/e2e/beta/from-import-beta-ui.spec.js index 5582d4697..e14ee2361 100644 --- a/test/e2e/beta/from-import-beta-ui.spec.js +++ b/test/e2e/beta/from-import-beta-ui.spec.js @@ -89,7 +89,14 @@ describe('Using MetaMask with an existing account', function () { await driver.wait(until.stalenessOf(overlay)) } catch (e) {} - const button = await findElement(driver, By.xpath("//button[contains(text(), 'Try it now')]")) + let button + try { + button = await findElement(driver, By.xpath("//button[contains(text(), 'Try it now')]")) + } catch (e) { + await loadExtension(driver, extensionId) + await delay(largeDelayMs) + button = await findElement(driver, By.xpath("//button[contains(text(), 'Try it now')]")) + } await button.click() await delay(regularDelayMs) diff --git a/test/e2e/beta/metamask-beta-ui.spec.js b/test/e2e/beta/metamask-beta-ui.spec.js index 6121878ba..20040505a 100644 --- a/test/e2e/beta/metamask-beta-ui.spec.js +++ b/test/e2e/beta/metamask-beta-ui.spec.js @@ -88,7 +88,14 @@ describe('MetaMask', function () { await driver.wait(until.stalenessOf(overlay)) } catch (e) {} - const button = await findElement(driver, By.xpath("//button[contains(text(), 'Try it now')]")) + let button + try { + button = await findElement(driver, By.xpath("//button[contains(text(), 'Try it now')]")) + } catch (e) { + await loadExtension(driver, extensionId) + await delay(largeDelayMs) + button = await findElement(driver, By.xpath("//button[contains(text(), 'Try it now')]")) + } await button.click() await delay(regularDelayMs) |