Describe the bug
Tests will fail unpredictably on main with this error:
Jest has detected the following 2 open handles potentially keeping Jest from exiting:
● DNSCHANNEL
at dns.js:333:23
● TCPWRAP
28 |
29 | if (process.env.REDIS_URL) {
> 30 | thinkyConn.r.redis = redis.createClient({ url: process.env.REDIS_URL });
| ^
31 | } else if (process.env.REDIS_FAKE) {
32 | const fakeredis = require("fakeredis");
33 | bluebird.promisifyAll(fakeredis.RedisClient.prototype);
at RedisClient.Object.<anonymous>.RedisClient.create_stream (node_modules/redis/index.js:251:31)
at new RedisClient (node_modules/redis/index.js:159:10)
at Object.<anonymous>.exports.createClient (node_modules/redis/index.js:1089:12)
at Object.createClient (src/server/models/thinky.js:30:30)
When you restart the build they often correct themselves.
To Reproduce
Steps to reproduce the behavior:
Additional context
I've specifically seen this problem on multiple PRs but haven't seen it yet running yarn test locally. Makes me think that there is a discrepancy there
@ibrand Can you link to a sample travis build that failed like this?
Here's one:
https://travis-ci.org/MoveOnOrg/Spoke/builds/617843694
Ah, note that the issue is: Timeout - Async callback was not invoked within the 10000ms timeout specified by jest.setTimeout. which I think was run with yarn test-cache
In our current stage-main, test-cache (vs. test-rediscache) is removed
and we also extend the timeout period
Should be fixed with https://github.com/MoveOnOrg/Spoke/pull/1287