Async callback was not invoked within the 5000 ms timeout specified by jest.setTimeout.Error: Timeout - Async callback was not invoked within the 5000 ms timeout specified by jest.setTimeout code example
Example 1: : Timeout - Async callback was not invoked within the 5000 ms timeout specified by jest.setTimeout.Timeout - Async callback was not invoked within the 5000 ms timeout specified by jest.setTimeout.Error:
beforeEach(() => {
jest.setTimeout(8000)
})
afterAll(() => {
jest.clearAllTimers()
})
Example 2: jest Async callback was not invoked within the 5000ms timeout specified by jest
module.exports = {
setupFilesAfterEnv: ['./jest.setup.js']
}
jest.setTimeout(30000)