We've been using Knapsack Pro with our Jest tests for several months now with no problems; however, when we bump our version of Jest to the latest (29.7.0), the runs in Github Actions go from ~10 minutes each to ~50. The initial load of the app has always been very slow; however, it's a one-time cost, as I believe Jest uses a local cache for subsequent runs. Instead of something like this:
// ...Knapsack API response...
PASS a.test.ts (3 s)
PASS b.test.ts (2 s)
PASS c.test.ts (3 s)
// ...Knapsack API response...
PASS d.test.ts (3 s)
PASS e.test.ts (2 s)
PASS f.test.ts (3 s)
...we're seeing this:
// ...Knapsack API response...
PASS a.test.ts (75 s)
PASS b.test.ts (2 s)
PASS c.test.ts (3 s)
// ...Knapsack API response...
PASS d.test.ts (74 s)
PASS e.test.ts (2 s)
PASS f.test.ts (3 s)
...with the first test of each Jest run taking longer than a minute.
Is our suspicion correct, that Jest is for some reason ignoring the cache and reloading all the modules each time now?
We've been using Knapsack Pro with our Jest tests for several months now with no problems; however, when we bump our version of Jest to the latest (29.7.0), the runs in Github Actions go from ~10 minutes each to ~50. The initial load of the app has always been very slow; however, it's a one-time cost, as I believe Jest uses a local cache for subsequent runs. Instead of something like this:
...we're seeing this:
...with the first test of each Jest run taking longer than a minute.
Is our suspicion correct, that Jest is for some reason ignoring the cache and reloading all the modules each time now?