diff options
author | Chocobozzz <me@florianbigard.com> | 2020-08-26 14:38:34 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2020-08-26 14:44:35 +0200 |
commit | c8bc2a1af698c21ea16ba56f077e507412f6b6ab (patch) | |
tree | 1ff4d10da8505f23e5b3076c04124094fbcacba7 /client/e2e/src/utils.ts | |
parent | 2199aaef6fcf37411dba401475be36c89eb325d3 (diff) | |
download | PeerTube-c8bc2a1af698c21ea16ba56f077e507412f6b6ab.tar.gz PeerTube-c8bc2a1af698c21ea16ba56f077e507412f6b6ab.tar.zst PeerTube-c8bc2a1af698c21ea16ba56f077e507412f6b6ab.zip |
Fix e2e tests
Diffstat (limited to 'client/e2e/src/utils.ts')
-rw-r--r-- | client/e2e/src/utils.ts | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/client/e2e/src/utils.ts b/client/e2e/src/utils.ts index e19da6402..a9d30c03a 100644 --- a/client/e2e/src/utils.ts +++ b/client/e2e/src/utils.ts | |||
@@ -1,11 +1,15 @@ | |||
1 | import { browser } from 'protractor' | 1 | import { browser } from 'protractor' |
2 | 2 | ||
3 | async function browserSleep (amount: number) { | 3 | async function browserSleep (amount: number) { |
4 | if (await isIOS()) browser.ignoreSynchronization = false | 4 | const oldValue = await browser.waitForAngularEnabled() |
5 | |||
6 | // iOS does not seem to work with protractor | ||
7 | // https://github.com/angular/protractor/issues/2840 | ||
8 | if (await isIOS()) browser.waitForAngularEnabled(true) | ||
5 | 9 | ||
6 | await browser.sleep(amount) | 10 | await browser.sleep(amount) |
7 | 11 | ||
8 | if (await isIOS()) browser.ignoreSynchronization = true | 12 | if (await isIOS()) browser.waitForAngularEnabled(oldValue) |
9 | } | 13 | } |
10 | 14 | ||
11 | async function isMobileDevice () { | 15 | async function isMobileDevice () { |