Skip to content

Wait for event loop to drain before exiting workers? #1718

@novemberborn

Description

@novemberborn

I'm considering changing the workers to not automatically exit once the last hook has finished. Ordinarily the event loop will drain and the process will exit on its own. However if some code is still running it could be part of a test. It may even call an assertion that should really cause the test to fail (see #1330).

Changing this behavior will encourage code that cleans up after itself. However I think we'd need an option to revert to the original behavior.

The --timeout option will apply to this to clean up workers that aren't exiting on their own. We should report the offending test files.

Interrupting AVA should do the same (see #583).

Thoughts?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions