Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fixup! test: fix flaky test-worker-message-port-transfer-self
  • Loading branch information
addaleax committed Sep 2, 2018
commit e394fb37b3f3bb200359e6a85ce3fa07a8cb98d5
2 changes: 1 addition & 1 deletion test/parallel/test-worker-message-port-transfer-self.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ port1.postMessage(2);

function tick(n, cb) {
if (--n > 0)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This actually makes half-the-n ticks, was this intentional?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nope. Thanks for catching!

return setImmediate(() => tick(n-1, cb));
return setImmediate(() => tick(n - 1, cb));
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is return needed here?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, removed it :)

else
cb();
}