Limits of Global Hooks in Mocha's Parallel Test Execution
Parallel Test Execution Overview Mocha 8.0.0 introduced the --parallel flag, which runs each test file in a separate worker process. This isolation removes shared global state between files and makes execution order nondeterministic. However, the framework does not explicitly document how global lifecycle hooks ( before , after , beforeEach , afterEach ) beh