From 0b21d0f99d5af79ad89261a872b709454dbf5d60 Mon Sep 17 00:00:00 2001 From: Matt Simerson Date: Wed, 17 Apr 2024 18:36:28 -0700 Subject: [PATCH] test: bump up DNS timeouts --- test/net_utils.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/net_utils.js b/test/net_utils.js index bcb1e2d..5c02c63 100644 --- a/test/net_utils.js +++ b/test/net_utils.js @@ -1331,6 +1331,7 @@ describe('get_mx', function () { }) describe('resolve_mx_hosts', function () { + beforeEach((done) => { this.net_utils = require('../index') done() @@ -1350,6 +1351,7 @@ describe('resolve_mx_hosts', function () { ] it('resolves mx hosts to IPs, tnpi.net', async () => { + this.timeout(5000) const r = await this.net_utils.resolve_mx_hosts([ { exchange: 'mail.theartfarm.com', priority: 10, from_dns: 'tnpi.net' }, ]) @@ -1357,6 +1359,7 @@ describe('resolve_mx_hosts', function () { }) it('resolves mx hosts to IPs, gmail.com', async () => { + this.timeout(5000) const mxes = await this.net_utils.get_mx('gmail.com') assert.equal(mxes.length, 5) const r = await this.net_utils.resolve_mx_hosts(mxes) @@ -1376,14 +1379,13 @@ describe('resolve_mx_hosts', function () { it('resolve_mx_hosts, gmail.com', async () => { const mxes = await this.net_utils.get_mx('gmail.com') const r = await this.net_utils.resolve_mx_hosts(mxes) - // console.log(r) assert.equal(r.length, 10) }) it('resolve_mx_hosts, yahoo.com', async () => { + this.timeout(5000) const mxes = await this.net_utils.get_mx('yahoo.com') const r = await this.net_utils.resolve_mx_hosts([mxes[0]]) - // console.log(r) assert.equal(r.length, 8) }) })