Skip to content
This repository has been archived by the owner on Oct 28, 2022. It is now read-only.

Commit

Permalink
Add 1 second pause at the beginning of each e2e test run (MetaMask#7872)
Browse files Browse the repository at this point in the history
There have been intermittent test failures at the beginning of various
e2e test runs. Most tests start with waiting for the 'Welcome' button
to be visible and enabled, which means waiting for the loading screen
to go away.

It looks like the reason the test intermittently fails is that
sometimes the loading screen doesn't appear until a few moments _after_
the page loads (or that it vanishes and comes back).

It was rather difficult to track down each possible cause for the
loading screens, so in the meantime a pause has been added at the start
of each run. This should hopefully suffice to ensure the momentary gap
in loading has been passed by the time the first test starts up.
  • Loading branch information
Gudahtt authored and yqrashawn committed Feb 3, 2020
1 parent 07f5d19 commit 6817de3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions test/e2e/webdriver/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ async function buildWebDriver ({ responsive, port } = {}) {
const driver = new Driver(seleniumDriver, browser, extensionUrl)
await driver.navigate()

await driver.delay(1000)

return {
driver,
extensionId,
Expand Down

0 comments on commit 6817de3

Please sign in to comment.