Skip to content
This repository was archived by the owner on Sep 19, 2018. It is now read-only.

Commit f12ed7e

Browse files
mantarohsideshowbarker
authored andcommitted
Fix EventWatcher example parameter, we should specify the test object in constructor.
1 parent 067d5e6 commit f12ed7e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

docs/api.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -216,11 +216,11 @@ Here's an example of how to use `EventWatcher`:
216216
var t = async_test("Event order on animation start");
217217

218218
var animation = watchedNode.getAnimations()[0];
219-
var eventWatcher = new EventWatcher(watchedNode, ['animationstart',
220-
'animationiteration',
221-
'animationend']);
219+
var eventWatcher = new EventWatcher(t, watchedNode, ['animationstart',
220+
'animationiteration',
221+
'animationend']);
222222

223-
eventWatcher.wait_for(t, 'animationstart').then(t.step_func(function() {
223+
eventWatcher.wait_for('animationstart').then(t.step_func(function() {
224224
assertExpectedStateAtStartOfAnimation();
225225
animation.currentTime = END_TIME; // skip to end
226226
// We expect two animationiteration events then an animationend event on

0 commit comments

Comments
 (0)