Skip to content

Commit

Permalink
fix(dev): pin to exact versions of linting tools and fix lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
retrohacker committed Jan 30, 2019
1 parent bb97ac0 commit 3740a6b
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 57 deletions.
8 changes: 4 additions & 4 deletions package.json
Expand Up @@ -125,10 +125,10 @@
"cover": "^0.2.9",
"coveralls": "^2.13.3",
"documentation": "^5.3.3",
"eslint": "^4.19.1",
"eslint": "4.19.1",
"eslint-config-prettier": "2.9.0",
"eslint-plugin-jsdoc": "^3.7.1",
"eslint-plugin-prettier": "^2.6.0",
"eslint-plugin-jsdoc": "3.15.1",
"eslint-plugin-prettier": "2.7.0",
"filed": "^0.1.0",
"glob": "^7.1.2",
"inquirer": "^3.3.0",
Expand All @@ -139,7 +139,7 @@
"nsp": "^2.8.1",
"ora": "^1.3.0",
"pre-commit": "^1.2.2",
"prettier": "^1.13.4",
"prettier": "1.16.1",
"proxyquire": "^1.8.0",
"restify-clients": "^1.5.2",
"rimraf": "^2.6.2",
Expand Down
18 changes: 6 additions & 12 deletions test/plugins/jsonBodyParser.test.js
Expand Up @@ -257,12 +257,9 @@ describe('JSON body parser', function() {
'\r\n' +
'{"foo":"bar"}';

var client = net.connect(
{ host: '127.0.0.1', port: PORT },
function() {
client.write(request);
}
);
var client = net.connect({ host: '127.0.0.1', port: PORT }, function() {
client.write(request);
});
client.once('data', function(data) {
client.end();
});
Expand Down Expand Up @@ -293,12 +290,9 @@ describe('JSON body parser', function() {
'\r\n' +
'{"foo":"bar"}';

var client = net.connect(
{ host: '127.0.0.1', port: PORT },
function() {
client.write(request);
}
);
var client = net.connect({ host: '127.0.0.1', port: PORT }, function() {
client.write(request);
});

client.once('data', function(data) {
client.end();
Expand Down
34 changes: 11 additions & 23 deletions test/plugins/static.test.js
Expand Up @@ -321,17 +321,11 @@ describe('static resource plugin', function() {
});
});

socket.connect(
{ host: '127.0.0.1', port: PORT },
function() {
socket.write(RAW_REQUEST, 'utf-8', function(
err2,
data
) {
assert.ifError(err2);
});
}
);
socket.connect({ host: '127.0.0.1', port: PORT }, function() {
socket.write(RAW_REQUEST, 'utf-8', function(err2, data) {
assert.ifError(err2);
});
});
});
}
);
Expand Down Expand Up @@ -369,18 +363,12 @@ describe('static resource plugin', function() {
});

var socket = new net.Socket();
socket.connect(
{ host: '127.0.0.1', port: PORT },
function() {
socket.write(RAW_REQUEST, 'utf-8', function(
err2,
data
) {
assert.ifError(err2);
socket.end();
});
}
);
socket.connect({ host: '127.0.0.1', port: PORT }, function() {
socket.write(RAW_REQUEST, 'utf-8', function(err2, data) {
assert.ifError(err2);
socket.end();
});
});
});
}
);
Expand Down
9 changes: 3 additions & 6 deletions test/serverHttp2.test.js
Expand Up @@ -53,12 +53,9 @@ before(function(cb) {
});
SERVER.listen(PORT, '127.0.0.1', function() {
PORT = SERVER.address().port;
CLIENT = http2.connect(
'https://127.0.0.1:' + PORT,
{
rejectUnauthorized: false
}
);
CLIENT = http2.connect('https://127.0.0.1:' + PORT, {
rejectUnauthorized: false
});

cb();
});
Expand Down
14 changes: 2 additions & 12 deletions test/upgrade.test.js
Expand Up @@ -304,12 +304,7 @@ test('GET with upgrade headers', function(t) {
t.equal(typeof socket, 'object');
t.ok(Buffer.isBuffer(head), 'head is Buffer');
t.doesNotThrow(function() {
var shed = WATERSHED.connect(
res,
socket,
head,
wskey
);
var shed = WATERSHED.connect(res, socket, head, wskey);
SHEDLIST.push(shed);
shed.end('ok, done');
shed.on('error', function(err3) {
Expand Down Expand Up @@ -380,12 +375,7 @@ test('GET with some websocket traffic', function(t) {
t.equal(typeof socket, 'object');
t.ok(Buffer.isBuffer(head), 'head is Buffer');
t.doesNotThrow(function() {
var shed = WATERSHED.connect(
res,
socket,
head,
wskey
);
var shed = WATERSHED.connect(res, socket, head, wskey);
SHEDLIST.push(shed);
shed.on('error', function(err3) {
t.ifError(err3);
Expand Down

0 comments on commit 3740a6b

Please sign in to comment.