Bug 1302707 - Remove GeckoDriver#setScriptTimeout; r?automatedtester draft
authorAndreas Tolfsen <ato@mozilla.com>
Wed, 14 Sep 2016 18:08:20 +0100
changeset 418518 6b5a10432776f750cd587604c56c7ec38a75ae77
parent 418456 b1d60f2f68c7cccc96fcf9a2075bb430a500a0f2
child 418519 7b02ff2404250b73f4f3bc2225feaa0068b9cce2
push id30699
push userbmo:ato@mozilla.com
push dateWed, 28 Sep 2016 16:44:24 +0000
reviewersautomatedtester
bugs1302707
milestone52.0a1
Bug 1302707 - Remove GeckoDriver#setScriptTimeout; r?automatedtester MozReview-Commit-ID: 3GVLpjd4LDP
testing/marionette/driver.js
--- a/testing/marionette/driver.js
+++ b/testing/marionette/driver.js
@@ -933,30 +933,16 @@ GeckoDriver.prototype.executeJSScript = 
 
     case Context.CONTENT:
       resp.body.value = yield this.listener.executeSimpleTest(script, args, scriptTimeout, opts);
       break;
   }
 };
 
 /**
- * Set the timeout for asynchronous script execution.
- *
- * @param {number} ms
- *     Time in milliseconds.
- */
-GeckoDriver.prototype.setScriptTimeout = function(cmd, resp) {
-  let ms = parseInt(cmd.parameters.ms);
-  if (isNaN(ms)) {
-    throw new WebDriverError("Not a Number");
-  }
-  this.scriptTimeout = ms;
-};
-
-/**
  * Navigate to given URL.
  *
  * Navigates the current browsing context to the given URL and waits for
  * the document to load or the session's page timeout duration to elapse
  * before returning.
  *
  * The command will return with a failure if there is an error loading
  * the document or the URL is blocked.  This can occur if it fails to
@@ -2706,17 +2692,16 @@ GeckoDriver.prototype.commands = {
   "sayHello": GeckoDriver.prototype.sayHello,
   "newSession": GeckoDriver.prototype.newSession,
   "getSessionCapabilities": GeckoDriver.prototype.getSessionCapabilities,
   "log": GeckoDriver.prototype.log,
   "getLogs": GeckoDriver.prototype.getLogs,
   "setContext": GeckoDriver.prototype.setContext,
   "getContext": GeckoDriver.prototype.getContext,
   "executeScript": GeckoDriver.prototype.executeScript,
-  "setScriptTimeout": GeckoDriver.prototype.setScriptTimeout,
   "timeouts": GeckoDriver.prototype.timeouts,
   "singleTap": GeckoDriver.prototype.singleTap,
   "actionChain": GeckoDriver.prototype.actionChain,
   "multiAction": GeckoDriver.prototype.multiAction,
   "executeAsyncScript": GeckoDriver.prototype.executeAsyncScript,
   "executeJSScript": GeckoDriver.prototype.executeJSScript,
   "setSearchTimeout": GeckoDriver.prototype.setSearchTimeout,
   "findElement": GeckoDriver.prototype.findElement,