Bug 1381876 - Rename WaitCondition to Condition. r?automatedtester
The condition can be used for other things than poll-waiting.
MozReview-Commit-ID: 1sudv5JuEQT
--- a/testing/marionette/wait.js
+++ b/testing/marionette/wait.js
@@ -13,17 +13,17 @@ this.EXPORTED_SYMBOLS = ["wait"];
/**
* Poll-waiting utilities.
*
* @namespace
*/
this.wait = {};
/**
- * @callback WaitCondition
+ * @callback Condition
*
* @param {function(*)} resolve
* To be called when the condition has been met. Will return the
* resolved value.
* @param {function} reject
* To be called when the condition has not been met. Will cause
* the condition to be revaluated or time out.
*
@@ -57,17 +57,17 @@ this.wait = {};
* if (res.length > 0) {
* resolve(Array.from(res));
* } else {
* reject([]);
* }
* });
* </pre></code>
*
- * @param {WaitCondition} func
+ * @param {Condition} func
* Function to run off the main thread.
* @param {number=} timeout
* Desired timeout. If 0 or less than the runtime evaluation time
* of |func|, |func| is guaranteed to run at least once. The default
* is 2000 milliseconds.
* @param {number=} interval
* Duration between each poll of |func| in milliseconds. Defaults to
* 10 milliseconds.