diff --git a/test/parallel/test-tls-0-dns-altname.js b/test/parallel/test-tls-0-dns-altname.js index 61458142bc0115..95ceb1aa59aaea 100644 --- a/test/parallel/test-tls-0-dns-altname.js +++ b/test/parallel/test-tls-0-dns-altname.js @@ -9,7 +9,6 @@ if (!common.hasCrypto) { var tls = require('tls'); var fs = require('fs'); -var net = require('net'); var common = require('../common'); diff --git a/test/parallel/test-tls-async-cb-after-socket-end.js b/test/parallel/test-tls-async-cb-after-socket-end.js index ea40205bfff06f..d89a4e9930ca6a 100644 --- a/test/parallel/test-tls-async-cb-after-socket-end.js +++ b/test/parallel/test-tls-async-cb-after-socket-end.js @@ -2,7 +2,6 @@ var common = require('../common'); -var assert = require('assert'); var path = require('path'); var fs = require('fs'); var constants = require('constants'); diff --git a/test/parallel/test-tls-client-default-ciphers.js b/test/parallel/test-tls-client-default-ciphers.js index e38671fd6f9de1..9905fc45bdcd24 100644 --- a/test/parallel/test-tls-client-default-ciphers.js +++ b/test/parallel/test-tls-client-default-ciphers.js @@ -19,7 +19,7 @@ function test1() { }; try { - var s = tls.connect(common.PORT); + tls.connect(common.PORT); } catch (e) { assert(e instanceof Done); } diff --git a/test/parallel/test-tls-close-error.js b/test/parallel/test-tls-close-error.js index 5c5a797c280a7d..bd38cb55f7a17b 100644 --- a/test/parallel/test-tls-close-error.js +++ b/test/parallel/test-tls-close-error.js @@ -10,7 +10,6 @@ if (!common.hasCrypto) { var tls = require('tls'); var fs = require('fs'); -var net = require('net'); var errorCount = 0; var closeCount = 0; diff --git a/test/parallel/test-tls-close-notify.js b/test/parallel/test-tls-close-notify.js index 5cc3021ab8dd7e..5545f4512d5f39 100644 --- a/test/parallel/test-tls-close-notify.js +++ b/test/parallel/test-tls-close-notify.js @@ -9,7 +9,6 @@ if (!common.hasCrypto) { var tls = require('tls'); var fs = require('fs'); -var net = require('net'); var ended = 0; diff --git a/test/parallel/test-tls-destroy-whilst-write.js b/test/parallel/test-tls-destroy-whilst-write.js index f42ed1d4ea7702..26c20264735926 100644 --- a/test/parallel/test-tls-destroy-whilst-write.js +++ b/test/parallel/test-tls-destroy-whilst-write.js @@ -1,5 +1,4 @@ 'use strict'; -var assert = require('assert'); var common = require('../common'); if (!common.hasCrypto) { diff --git a/test/parallel/test-tls-fast-writing.js b/test/parallel/test-tls-fast-writing.js index 009fa40b631ee5..1f65391480d59d 100644 --- a/test/parallel/test-tls-fast-writing.js +++ b/test/parallel/test-tls-fast-writing.js @@ -20,7 +20,7 @@ var server = tls.createServer(options, onconnection); var gotChunk = false; var gotDrain = false; -var timer = setTimeout(function() { +setTimeout(function() { console.log('not ok - timed out'); process.exit(1); }, common.platformTimeout(500)); diff --git a/test/parallel/test-tls-handshake-error.js b/test/parallel/test-tls-handshake-error.js index f33177455f8943..f65440ed93b1a3 100644 --- a/test/parallel/test-tls-handshake-error.js +++ b/test/parallel/test-tls-handshake-error.js @@ -10,7 +10,6 @@ if (!common.hasCrypto) { var tls = require('tls'); var fs = require('fs'); -var net = require('net'); var errorCount = 0; var closeCount = 0; diff --git a/test/parallel/test-tls-handshake-nohang.js b/test/parallel/test-tls-handshake-nohang.js index ae07551ef98088..374ac02a2f45b5 100644 --- a/test/parallel/test-tls-handshake-nohang.js +++ b/test/parallel/test-tls-handshake-nohang.js @@ -1,6 +1,5 @@ 'use strict'; var common = require('../common'); -var assert = require('assert'); if (!common.hasCrypto) { console.log('1..0 # Skipped: missing crypto'); diff --git a/test/parallel/test-tls-invoke-queued.js b/test/parallel/test-tls-invoke-queued.js index f833108ea3f9e0..efa5c0aa9aa31d 100644 --- a/test/parallel/test-tls-invoke-queued.js +++ b/test/parallel/test-tls-invoke-queued.js @@ -9,7 +9,6 @@ if (!common.hasCrypto) { var tls = require('tls'); var fs = require('fs'); -var net = require('net'); var received = ''; diff --git a/test/parallel/test-tls-key-mismatch.js b/test/parallel/test-tls-key-mismatch.js index f7919c545aefb1..2e17a4931078c7 100644 --- a/test/parallel/test-tls-key-mismatch.js +++ b/test/parallel/test-tls-key-mismatch.js @@ -14,8 +14,6 @@ var options = { cert: fs.readFileSync(common.fixturesDir + '/keys/agent2-cert.pem') }; -var cert = null; - assert.throws(function() { tls.createSecureContext(options); }); diff --git a/test/parallel/test-tls-max-send-fragment.js b/test/parallel/test-tls-max-send-fragment.js index cc9413b81e78d6..8b1bf0998aad30 100644 --- a/test/parallel/test-tls-max-send-fragment.js +++ b/test/parallel/test-tls-max-send-fragment.js @@ -9,7 +9,6 @@ if (!common.hasCrypto) { var tls = require('tls'); var fs = require('fs'); -var net = require('net'); var common = require('../common'); diff --git a/test/parallel/test-tls-ocsp-callback.js b/test/parallel/test-tls-ocsp-callback.js index a11be7ac22d1c5..e9443f45357995 100644 --- a/test/parallel/test-tls-ocsp-callback.js +++ b/test/parallel/test-tls-ocsp-callback.js @@ -41,7 +41,6 @@ function test(testOptions, cb) { var clientSecure = 0; var ocspCount = 0; var ocspResponse; - var session; if (testOptions.pfx) { delete options.key; diff --git a/test/parallel/test-tls-peer-certificate-encoding.js b/test/parallel/test-tls-peer-certificate-encoding.js index 96cb6944ef6a97..32b1583a0c4840 100644 --- a/test/parallel/test-tls-peer-certificate-encoding.js +++ b/test/parallel/test-tls-peer-certificate-encoding.js @@ -11,7 +11,6 @@ var tls = require('tls'); var fs = require('fs'); var util = require('util'); var join = require('path').join; -var spawn = require('child_process').spawn; var options = { key: fs.readFileSync(join(common.fixturesDir, 'keys', 'agent5-key.pem')), diff --git a/test/parallel/test-tls-peer-certificate-multi-keys.js b/test/parallel/test-tls-peer-certificate-multi-keys.js index fca7a1a77dda67..50ce9037f8d755 100644 --- a/test/parallel/test-tls-peer-certificate-multi-keys.js +++ b/test/parallel/test-tls-peer-certificate-multi-keys.js @@ -11,7 +11,6 @@ var tls = require('tls'); var fs = require('fs'); var util = require('util'); var join = require('path').join; -var spawn = require('child_process').spawn; var options = { key: fs.readFileSync(join(common.fixturesDir, 'agent.key')), diff --git a/test/parallel/test-tls-peer-certificate.js b/test/parallel/test-tls-peer-certificate.js index 3cb0eef2d56268..cdf8bf5644f675 100644 --- a/test/parallel/test-tls-peer-certificate.js +++ b/test/parallel/test-tls-peer-certificate.js @@ -11,7 +11,6 @@ var tls = require('tls'); var fs = require('fs'); var util = require('util'); var join = require('path').join; -var spawn = require('child_process').spawn; var options = { key: fs.readFileSync(join(common.fixturesDir, 'keys', 'agent1-key.pem')), diff --git a/test/parallel/test-tls-request-timeout.js b/test/parallel/test-tls-request-timeout.js index a9b1c78c91a0bf..0db2a613afc9e4 100644 --- a/test/parallel/test-tls-request-timeout.js +++ b/test/parallel/test-tls-request-timeout.js @@ -29,7 +29,7 @@ var server = tls.Server(options, function(socket) { }); server.listen(common.PORT, function() { - var socket = tls.connect({ + tls.connect({ port: common.PORT, rejectUnauthorized: false }); diff --git a/test/parallel/test-tls-socket-default-options.js b/test/parallel/test-tls-socket-default-options.js index 7b41d0f5a9ec23..c2c6e518bbc4d8 100644 --- a/test/parallel/test-tls-socket-default-options.js +++ b/test/parallel/test-tls-socket-default-options.js @@ -9,7 +9,6 @@ if (!common.hasCrypto) { const tls = require('tls'); const fs = require('fs'); -const net = require('net'); const sent = 'hello world'; diff --git a/test/parallel/test-tls-ticket-cluster.js b/test/parallel/test-tls-ticket-cluster.js index fc0f1d5e858d00..1fd1776ca8199f 100644 --- a/test/parallel/test-tls-ticket-cluster.js +++ b/test/parallel/test-tls-ticket-cluster.js @@ -42,7 +42,6 @@ if (cluster.isMaster) { function fork() { var worker = cluster.fork(); - var workerReqCount = 0; worker.on('message', function(msg) { console.error('[master] got %j', msg); if (msg === 'reused') {