Backed out changeset 135c1e44a92b (bug 1404946)
authorSebastian Hengst <archaeopteryx@coole-files.de>
Mon, 09 Oct 2017 16:23:10 +0200
changeset 385116 ff635ffa3ab790e0369ba447a3419d731a5ef53b
parent 385115 35beb8d02dcc9069d97cbc6530cfe7344763fd60
child 385117 7aec94f0c517cd3758c2cc3bee25136a37133c02
push id52896
push userarchaeopteryx@coole-files.de
push dateMon, 09 Oct 2017 14:24:20 +0000
treeherderautoland@7aec94f0c517 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1404946
milestone58.0a1
backs out135c1e44a92b0a5122c56c4a57b742db117a2821
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Backed out changeset 135c1e44a92b (bug 1404946)
testing/marionette/sync.js
--- a/testing/marionette/sync.js
+++ b/testing/marionette/sync.js
@@ -34,34 +34,30 @@ const {TYPE_ONE_SHOT, TYPE_REPEATING_SLA
  *     the condition to be revaluated or time out.
  *
  * @return {*}
  *     The value from calling <code>resolve</code>.
  */
 
 /**
  * Runs a promise-like function off the main thread until it is resolved
- * through <code>resolve</code> or <code>rejected</code> callbacks.
- * The function is guaranteed to be run at least once, irregardless of
- * the timeout.
+ * through |resolve| or |rejected| callbacks.  The function is guaranteed
+ * to be run at least once, irregardless of the timeout.
  *
- * The <var>func</var> is evaluated every <var>interval</var> for as
- * long as its runtime duration does not exceed <var>interval</var>.
- * Evaluations occur sequentially, meaning that evaluations of
- * <var>func</var> are queued if the runtime evaluation duration of
- * <var>func</var> is greater than <var>interval</var>.
+ * The |func| is evaluated every |interval| for as long as its runtime
+ * duration does not exceed |interval|.  Evaluations occur sequentially,
+ * meaning that evaluations of |func| are queued if the runtime evaluation
+ * duration of |func| is greater than |interval|.
  *
- * <var>func</var> is given two arguments, <code>resolve</code> and
- * <code>reject</code>, of which one must be called for the evaluation
- * to complete.  Calling <code>resolve</code> with an argument
- * indicates that the expected wait condition was met and will return
- * the passed value to the caller.  Conversely, calling
- * <code>reject</code> will evaluate <var>func</var> again until
- * the <var>timeout</var> duration has elapsed or <var>func</var>
- * throws.  The passed value to <code>reject</code> will also be
+ * |func| is given two arguments, |resolve| and |reject|, of which one
+ * must be called for the evaluation to complete.  Calling |resolve| with
+ * an argument indicates that the expected wait condition was met and
+ * will return the passed value to the caller.  Conversely, calling
+ * |reject| will evaluate |func| again until the |timeout| duration has
+ * elapsed or |func| throws.  The passed value to |reject| will also be
  * returned to the caller once the wait has expired.
  *
  * Usage:
  *
  * <pre><code>
  *     let els = wait.until((resolve, reject) => {
  *       let res = document.querySelectorAll("p");
  *       if (res.length > 0) {
@@ -69,30 +65,30 @@ const {TYPE_ONE_SHOT, TYPE_REPEATING_SLA
  *       } else {
  *         reject([]);
  *       }
  *     });
  * </pre></code>
  *
  * @param {Condition} func
  *     Function to run off the main thread.
- * @param {number=} [timeout=2000] timeout
- *     Desired timeout.  If 0 or less than the runtime evaluation
- *     time of <var>func</var>, <var>func</var> is guaranteed to run
- *     at least once.  The default is 2000 milliseconds.
- * @param {number=} [interval=10] interval
- *     Duration between each poll of <var>func</var> in milliseconds.
- *     Defaults to 10 milliseconds.
+ * @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.
  *
  * @return {Promise.<*>}
- *     Yields the value passed to <var>func</var>'s
- *     <code>resolve</code> or <code>reject</code> callbacks.
+ *     Yields the value passed to |func|'s |resolve| or |reject|
+ *     callbacks.
  *
  * @throws {*}
- *     If <var>func</var> throws, its error is propagated.
+ *     If |func| throws, its error is propagated.
  */
 wait.until = function(func, timeout = 2000, interval = 10) {
   const timer = Cc["@mozilla.org/timer;1"].createInstance(Ci.nsITimer);
 
   return new Promise((resolve, reject) => {
     const start = new Date().getTime();
     const end = start + timeout;