You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by al...@apache.org on 2016/06/08 11:04:40 UTC
cordova-paramedic git commit: Sauce testing: Fixed occasional Appium
context failures
Repository: cordova-paramedic
Updated Branches:
refs/heads/master c978171a2 -> d21b72d16
Sauce testing: Fixed occasional Appium context failures
Project: http://git-wip-us.apache.org/repos/asf/cordova-paramedic/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-paramedic/commit/d21b72d1
Tree: http://git-wip-us.apache.org/repos/asf/cordova-paramedic/tree/d21b72d1
Diff: http://git-wip-us.apache.org/repos/asf/cordova-paramedic/diff/d21b72d1
Branch: refs/heads/master
Commit: d21b72d16e830fb4de792af17c490719172c1fff
Parents: c978171
Author: Alexander Sorokin <al...@akvelon.com>
Authored: Wed Jun 8 14:04:29 2016 +0300
Committer: Alexander Sorokin <al...@akvelon.com>
Committed: Wed Jun 8 14:04:29 2016 +0300
----------------------------------------------------------------------
lib/appium/helpers/wdHelper.js | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-paramedic/blob/d21b72d1/lib/appium/helpers/wdHelper.js
----------------------------------------------------------------------
diff --git a/lib/appium/helpers/wdHelper.js b/lib/appium/helpers/wdHelper.js
index e315422..7e867aa 100644
--- a/lib/appium/helpers/wdHelper.js
+++ b/lib/appium/helpers/wdHelper.js
@@ -80,6 +80,7 @@ module.exports.getWebviewContext = function (driver, retries) {
retries = 2;
}
return driver
+ .sleep(WEBVIEW_WAIT_TIMEOUT)
.contexts()
.then(function (contexts) {
// take the last webview context
@@ -92,14 +93,13 @@ module.exports.getWebviewContext = function (driver, retries) {
return driver
.then(function () {
if (retries > 0) {
- console.log('Couldn\'t get webview context. Retries remaining: ' + retries);
+ console.log('No webview context. Retries remaining: ' + retries);
return driver
- .sleep(WEBVIEW_WAIT_TIMEOUT)
.then(function () {
return module.exports.getWebviewContext(driver, retries - 1);
});
}
- throw 'Couldn\'t get webview context. Failing...';
+ throw 'Couldn\'t get webview context.';
});
});
};
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org