mirror of
https://github.com/nodejs/node.git
synced 2024-11-22 07:37:56 +01:00
fddd3ffa59
PR-URL: https://github.com/nodejs/node/pull/48464 Fixes: https://github.com/npm/cli/issues/6409 Fixes: https://github.com/KararTY/dank-twitch-irc/issues/13 Fixes: https://github.com/nodejs/node/issues/47644 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
21 lines
531 B
JavaScript
21 lines
531 B
JavaScript
'use strict';
|
|
|
|
const common = require('../common');
|
|
const { addresses } = require('../common/internet');
|
|
|
|
if (!common.hasCrypto)
|
|
common.skip('missing crypto');
|
|
|
|
const assert = require('assert');
|
|
const { request } = require('https');
|
|
|
|
request(
|
|
`https://${addresses.INET_HOST}/en`,
|
|
// Purposely set this to a low value because we want all connection but the last to fail
|
|
{ autoSelectFamily: true, autoSelectFamilyAttemptTimeout: 10 },
|
|
(res) => {
|
|
assert.strictEqual(res.statusCode, 200);
|
|
res.resume();
|
|
},
|
|
).end();
|