I have updated recently to [email protected]__ and using my old config file appears the following error:
Jest did not exit one second after the test run has completed.
This usually means that there are asynchronous operations that weren't stopped in your tests. Consider running Jest with '--detectOpenHandles' to troubleshoot this issue.
This error disappears when removing the notify option from the configuration file.
Install [email protected]__, create a simple test file true.test.js:
test('True to be true!', () => expect(true).toBe(true));
Create a jest.config.js file and add this content:
module.exports = {
notify: true,
};
Run Jest from the __package.json__ test script:
{
"scripts": {
"test": "jest"
}
}
I expect to obtain notification when finished (appers, but long after finished), and a clean output with the coverage summary. Instead, I obtain the error message. And when removing the notification option, I obtain a clean output, but no coverage summary (not sure if the missing summary is related, but both appear at the same time).
This is the output with [email protected]__, same error, and no coverage summary:

This is the output with [email protected]__, same error, but with the coverage summary:

This is the output with [email protected]__, no error and coverage summary (but I needed to add testURL: 'http://localhost/' to the config file to pass the tests):

jest-bug. Please, just clone the repo, npm install and npm test.
Thanks a lot for your help.
npx envinfo --preset jestSystem:
OS: macOS 10.14.3
CPU: (4) x64 Intel(R) Core(TM) i7-6660U CPU @ 2.40GHz
Binaries:
Node: 11.9.0 - /usr/local/bin/node
Yarn: 1.13.0 - /usr/local/bin/yarn
npm: 6.7.0 - /usr/local/bin/npm
npmPackages:
jest: ^24.1.0 => 24.1.0
I am having the same issue as well. I have tried removing & adding the flag & the error only appears when the flag is present.
OK. It seems that the coverage summary is not an error. It has stopped being automatic. Now it's needed to be configured in coverageReporters option.
{
coverageReporters: ['text-summary'],
}
And for now, the timeout problem can be avoided using jest --detectOpenHandles. This is the result with the new configuration using [email protected]__.

I still think the issue with --notify is a bug & using --detectOpenHandles would be a band aid solution.
This should be fixed after the change in node-notifier was reverted in 5.4.1. Update your lockfile and you should be good
It reproduces for me with "node-notifier": "^6.0.0"
Yeah, fixed in #9567
Yeah, fixed in #9567
I've just updated packages, but problem still persists
Fix is not released
Most helpful comment
This should be fixed after the change in node-notifier was reverted in 5.4.1. Update your lockfile and you should be good