79517245

Date: 2025-03-18 11:35:08
Score: 1.5
Natty:
Report link

Why do you want to load database fixture after test execution (afterAll method) ?

As reported in the official documentation (https://jestjs.io/docs/setup-teardown) you only need to do setup once, typically in the beforeAll() method.

If you are already doing this and still have this error then maybe there are still unresolved async operations.

Try to do something like this:

beforeAll(async () => {
   await loadFixture()
});

Reasons:
  • Has code block (-0.5):
  • Contains question mark (0.5):
  • Starts with a question (0.5): Why do you
  • Low reputation (1):
Posted by: Andrea Acampora