diff options
author | Rich Trott <rtrott@gmail.com> | 2019-03-23 09:37:32 -0700 |
---|---|---|
committer | Rich Trott <rtrott@gmail.com> | 2019-03-24 07:56:20 -0700 |
commit | f5969f08a0be666b3e95a185fa34f9554a5f6ffc (patch) | |
tree | 0048bb88e7d49208879c2bb22563e5d8208f8282 /test | |
parent | 229759f961e0c9f37539c24fb06b37b60d4dc352 (diff) | |
download | android-node-v8-f5969f08a0be666b3e95a185fa34f9554a5f6ffc.tar.gz android-node-v8-f5969f08a0be666b3e95a185fa34f9554a5f6ffc.tar.bz2 android-node-v8-f5969f08a0be666b3e95a185fa34f9554a5f6ffc.zip |
test: replace localhost IP with 'localhost' for TLS conformity
test-https-connect-localport currently causes a runtime deprecation
warning: "[DEP0123] DeprecationWarning: Setting the TLS ServerName
to an IP address is not permitted by RFC 6066. This will be ignored
in a future version."
Change IP usage to the string 'localhost' instead.
PR-URL: https://github.com/nodejs/node/pull/26881
Fixes: https://github.com/https://github.com/nodejs/node/issues/26862
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/sequential/test-https-connect-localport.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/sequential/test-https-connect-localport.js b/test/sequential/test-https-connect-localport.js index d703d2813c..67b56c7d7d 100644 --- a/test/sequential/test-https-connect-localport.js +++ b/test/sequential/test-https-connect-localport.js @@ -15,10 +15,10 @@ const assert = require('assert'); }, common.mustCall(function(req, res) { this.close(); res.end(); - })).listen(0, common.localhostIPv4, common.mustCall(function() { + })).listen(0, 'localhost', common.mustCall(function() { const port = this.address().port; const req = https.get({ - host: common.localhostIPv4, + host: 'localhost', pathname: '/', port, family: 4, |