mirror of
https://github.com/nodejs/node.git
synced 2024-11-30 07:27:22 +01:00
test: cleanup cluster-disconnect-unshared-tcp test
Replaced var with const PR-URL: https://github.com/nodejs/node/pull/8598 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Ilkka Myller <ilkka.myller@nodefield.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
parent
7a46554dcf
commit
0f7fffb329
@ -2,11 +2,11 @@
|
||||
require('../common');
|
||||
process.env.NODE_CLUSTER_SCHED_POLICY = 'none';
|
||||
|
||||
var cluster = require('cluster');
|
||||
var net = require('net');
|
||||
const cluster = require('cluster');
|
||||
const net = require('net');
|
||||
|
||||
if (cluster.isMaster) {
|
||||
var unbound = cluster.fork().on('online', bind);
|
||||
const unbound = cluster.fork().on('online', bind);
|
||||
|
||||
function bind() {
|
||||
cluster.fork({BOUND: 'y'}).on('listening', disconnect);
|
||||
@ -18,7 +18,7 @@ if (cluster.isMaster) {
|
||||
}
|
||||
} else {
|
||||
if (process.env.BOUND === 'y') {
|
||||
var source = net.createServer();
|
||||
const source = net.createServer();
|
||||
|
||||
source.listen(0);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user