Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
test: use shorthand properties in net tests
  • Loading branch information
tniessen committed Jan 11, 2018
commit d39d950f07c5088a960474ee48d1454dce86c844
2 changes: 1 addition & 1 deletion test/parallel/test-net-connect-options-port.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ const net = require('net');
{
// connect({hint}, cb) and connect({hint})
const hints = (dns.ADDRCONFIG | dns.V4MAPPED) + 42;
const hintOptBlocks = doConnect([{ hints: hints }],
const hintOptBlocks = doConnect([{ hints }],
() => common.mustNotCall());
for (const block of hintOptBlocks) {
common.expectsError(block, {
Expand Down
2 changes: 1 addition & 1 deletion test/parallel/test-net-server-listen-handle.js
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ if (!common.isWindows) { // Windows doesn't support {fd: <n>}
// Test invalid fd
const fd = fs.openSync(__filename, 'r');
net.createServer()
.listen({ fd: fd }, common.mustNotCall())
.listen({ fd }, common.mustNotCall())
.on('error', common.mustCall(function(err) {
assert.strictEqual(String(err), 'Error: listen EINVAL');
this.close();
Expand Down
2 changes: 1 addition & 1 deletion test/parallel/test-net-server-listen-options.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ function close() { this.close(); }
.on('listening', common.mustCall(close));
}

// Test listen(port, cb) and listen({port: port}, cb) combinations
// Test listen(port, cb) and listen({ port }, cb) combinations
const listenOnPort = [
(port, cb) => net.createServer().listen({ port }, cb),
(port, cb) => net.createServer().listen(port, cb)
Expand Down