Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(circus): enable writing async test event handlers #9397

Merged
merged 15 commits into from
Apr 8, 2020
Merged
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
Update e2e/test-environment-circus/CircusAsyncHandleTestEventEnvironm…
…ent.js

Co-Authored-By: Simen Bekkhus <sbekkhus91@gmail.com>
  • Loading branch information
noomorph and SimenB committed Apr 3, 2020
commit 2900542e4bc9224c337756a55061cf873262c553
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ class TestEnvironment extends BaseTestEnvironment {

if (isAsyncEvent(event)) {
this.pendingEvents.add(event);
await sleep(0).then(() => this.pendingEvents.delete(event));
await sleep(0);
await this.pendingEvents.delete(event);
}

await super.handleTestEvent(event);
Expand Down