Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit bc39d6a

Browse filesBrowse files
Trottjasnell
authored andcommitted
test: remove unused vars
Remove unused vars in tests PR-URL: #4536 Reviewed-By: Rod Vagg <rod@vagg.org> Reviewed-By: Michaël Zasso <mic.besace@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
1 parent a497bb5 commit bc39d6a
Copy full SHA for bc39d6a
Expand file treeCollapse file tree

24 files changed

+24
-45
lines changed
Open diff view settings
Collapse file

‎test/addons/repl-domain-abort/test.js‎

Copy file name to clipboardExpand all lines: test/addons/repl-domain-abort/test.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,4 +46,4 @@ var options = {
4646
};
4747

4848
// Run commands from fake REPL.
49-
var dummy = repl.start(options);
49+
repl.start(options);
Collapse file

‎test/debugger/test-debugger-pid.js‎

Copy file name to clipboardExpand all lines: test/debugger/test-debugger-pid.js
+1-8Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,9 @@
11
'use strict';
2-
var common = require('../common');
2+
require('../common');
33
var assert = require('assert');
44
var spawn = require('child_process').spawn;
55

6-
var port = common.PORT + 1337;
76
var buffer = '';
8-
var expected = [];
9-
var scriptToDebug = common.fixturesDir + '/empty.js';
10-
11-
function fail() {
12-
assert(0); // `--debug-brk script.js` should not quit
13-
}
147

158
// connect to debug agent
169
var interfacer = spawn(process.execPath, ['debug', '-p', '655555']);
Collapse file

‎test/debugger/test-debugger-remote.js‎

Copy file name to clipboardExpand all lines: test/debugger/test-debugger-remote.js
-2Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,7 @@ var common = require('../common');
33
var assert = require('assert');
44
var spawn = require('child_process').spawn;
55

6-
var port = common.PORT + 1337;
76
var buffer = '';
8-
var expected = [];
97
var scriptToDebug = common.fixturesDir + '/empty.js';
108

119
function fail() {
Collapse file

‎test/internet/test-dns.js‎

Copy file name to clipboardExpand all lines: test/internet/test-dns.js
+2-3Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ require('../common');
33
var assert = require('assert'),
44
dns = require('dns'),
55
net = require('net'),
6-
isIP = net.isIP,
76
isIPv4 = net.isIPv4,
87
isIPv6 = net.isIPv6;
98
var util = require('util');
@@ -48,7 +47,7 @@ TEST(function test_reverse_bogus(done) {
4847
var error;
4948

5049
try {
51-
var req = dns.reverse('bogus ip', function() {
50+
dns.reverse('bogus ip', function() {
5251
assert.ok(false);
5352
});
5453
} catch (e) {
@@ -369,7 +368,7 @@ console.log('looking up nodejs.org...');
369368

370369
var cares = process.binding('cares_wrap');
371370
var req = new cares.GetAddrInfoReqWrap();
372-
var err = cares.getaddrinfo(req, 'nodejs.org', 4);
371+
cares.getaddrinfo(req, 'nodejs.org', 4);
373372

374373
req.oncomplete = function(err, domains) {
375374
assert.strictEqual(err, 0);
Collapse file

‎test/parallel/test-domain-exit-dispose-again.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-domain-exit-dispose-again.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
// to that domain, including those whose callbacks are called from within
66
// the same invocation of listOnTimeout, _are_ called.
77

8-
var common = require('../common');
8+
require('../common');
99
var assert = require('assert');
1010
var domain = require('domain');
1111
var disposalFailed = false;
Collapse file

‎test/parallel/test-domain-implicit-fs.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-domain-implicit-fs.js
-1Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
require('../common');
55
var assert = require('assert');
66
var domain = require('domain');
7-
var events = require('events');
87
var caught = 0;
98
var expectCaught = 1;
109

Collapse file

‎test/parallel/test-http-agent-error-on-idle.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-http-agent-error-on-idle.js
-1Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ function get(callback) {
2121
return http.get(requestParams, callback);
2222
}
2323

24-
var destroy_queue = {};
2524
var server = http.createServer(function(req, res) {
2625
res.end('hello world');
2726
});
Collapse file

‎test/parallel/test-timers-throw-when-cb-not-function.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-timers-throw-when-cb-not-function.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
'use strict';
2-
const common = require('../common');
2+
require('../common');
33
const assert = require('assert');
44

55
function doSetTimeout(callback, after) {
Collapse file

‎test/parallel/test-vm-create-context-arg.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-vm-create-context-arg.js
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ var assert = require('assert');
44
var vm = require('vm');
55

66
assert.throws(function() {
7-
var ctx = vm.createContext('string is not supported');
7+
vm.createContext('string is not supported');
88
}, TypeError);
99

1010
assert.doesNotThrow(function() {
11-
var ctx = vm.createContext({ a: 1 });
12-
ctx = vm.createContext([0, 1, 2, 3]);
11+
vm.createContext({ a: 1 });
12+
vm.createContext([0, 1, 2, 3]);
1313
});
1414

1515
assert.doesNotThrow(function() {
Collapse file

‎test/parallel/test-vm-harmony-proxies.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-vm-harmony-proxies.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@ var vm = require('vm');
88
// src/node_contextify.cc filters out the Proxy object from the parent
99
// context. Make sure that the new context has a Proxy object of its own.
1010
var sandbox = {};
11-
var result = vm.runInNewContext('this.Proxy = Proxy', sandbox);
11+
vm.runInNewContext('this.Proxy = Proxy', sandbox);
1212
assert(typeof sandbox.Proxy === 'object');
1313
assert(sandbox.Proxy !== Proxy);
1414

1515
// Unless we copy the Proxy object explicitly, of course.
1616
var sandbox = { Proxy: Proxy };
17-
var result = vm.runInNewContext('this.Proxy = Proxy', sandbox);
17+
vm.runInNewContext('this.Proxy = Proxy', sandbox);
1818
assert(typeof sandbox.Proxy === 'object');
1919
assert(sandbox.Proxy === Proxy);

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.