зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1702271 - Document waitForCondition msg arg. r=florian DONTBUILD
This also makes a couple of other fixes to existing comments to bring them in line with the actual behaviour and names used. Differential Revision: https://phabricator.services.mozilla.com/D110428
This commit is contained in:
Родитель
30b2db3912
Коммит
bb3170ecf7
|
@ -149,12 +149,17 @@ var TestUtils = {
|
|||
*
|
||||
* @param condition
|
||||
* A condition function that must return true or false. If the
|
||||
* condition ever throws, this is also treated as a false. The
|
||||
* function can be an async function.
|
||||
* condition ever throws, this function fails and rejects the
|
||||
* returned promise. The function can be an async function.
|
||||
* @param msg
|
||||
* A message used to describe the condition being waited for.
|
||||
* This message will be used to reject the promise should the
|
||||
* wait fail. It is also used to add a profiler marker in the
|
||||
* success case.
|
||||
* @param interval
|
||||
* The time interval to poll the condition function. Defaults
|
||||
* to 100ms.
|
||||
* @param attempts
|
||||
* @param maxTries
|
||||
* The number of times to poll before giving up and rejecting
|
||||
* if the condition has not yet returned true. Defaults to 50
|
||||
* (~5 seconds for 100ms intervals)
|
||||
|
|
Загрузка…
Ссылка в новой задаче