Skip to content

Commit 7e739ae

Browse files
TrottMyles Borins
authored andcommitted
test,tools: adjust function argument alignment
In preparation for a lint rule enforcing function argument alignment, adjust function arguments to be aligned. PR-URL: #7100 Refs: #6390 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Johan Bergström <bugs@bergstroem.nu> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Imran Iqbal <imran@imraniqbal.org> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Ryan Graham <r.m.graham@gmail.com>
1 parent 90306bb commit 7e739ae

25 files changed

+83
-63
lines changed

test/internet/test-dgram-multicast-multi-process.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ function launchChildProcess(index) {
9191
worker.pid, count);
9292

9393
assert.strictEqual(count, messages.length,
94-
'A worker received an invalid multicast message');
94+
'A worker received an invalid multicast message');
9595
});
9696

9797
clearTimeout(timer);

test/parallel/test-assert.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -461,7 +461,7 @@ try {
461461
} catch (e) {
462462
assert.equal(e.toString().split('\n')[0], 'AssertionError: oh no');
463463
assert.equal(e.generatedMessage, false,
464-
'Message incorrectly marked as generated');
464+
'Message incorrectly marked as generated');
465465
}
466466

467467
// Verify that throws() and doesNotThrow() throw on non-function block

test/parallel/test-buffer.js

Lines changed: 24 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -571,18 +571,30 @@ assert.equal(new Buffer('KioqKioqKioqKioqKioqKioqKio', 'base64').toString(),
571571
'********************');
572572

573573
// handle padding graciously, multiple-of-4 or not
574-
assert.equal(new Buffer('72INjkR5fchcxk9+VgdGPFJDxUBFR5/rMFsghgxADiw==',
575-
'base64').length, 32);
576-
assert.equal(new Buffer('72INjkR5fchcxk9+VgdGPFJDxUBFR5/rMFsghgxADiw=',
577-
'base64').length, 32);
578-
assert.equal(new Buffer('72INjkR5fchcxk9+VgdGPFJDxUBFR5/rMFsghgxADiw',
579-
'base64').length, 32);
580-
assert.equal(new Buffer('w69jACy6BgZmaFvv96HG6MYksWytuZu3T1FvGnulPg==',
581-
'base64').length, 31);
582-
assert.equal(new Buffer('w69jACy6BgZmaFvv96HG6MYksWytuZu3T1FvGnulPg=',
583-
'base64').length, 31);
584-
assert.equal(new Buffer('w69jACy6BgZmaFvv96HG6MYksWytuZu3T1FvGnulPg',
585-
'base64').length, 31);
574+
assert.equal(
575+
new Buffer('72INjkR5fchcxk9+VgdGPFJDxUBFR5/rMFsghgxADiw==', 'base64').length,
576+
32
577+
);
578+
assert.equal(
579+
new Buffer('72INjkR5fchcxk9+VgdGPFJDxUBFR5/rMFsghgxADiw=', 'base64').length,
580+
32
581+
);
582+
assert.equal(
583+
new Buffer('72INjkR5fchcxk9+VgdGPFJDxUBFR5/rMFsghgxADiw', 'base64').length,
584+
32
585+
);
586+
assert.equal(
587+
new Buffer('w69jACy6BgZmaFvv96HG6MYksWytuZu3T1FvGnulPg==', 'base64').length,
588+
31
589+
);
590+
assert.equal(
591+
new Buffer('w69jACy6BgZmaFvv96HG6MYksWytuZu3T1FvGnulPg=', 'base64').length,
592+
31
593+
);
594+
assert.equal(
595+
new Buffer('w69jACy6BgZmaFvv96HG6MYksWytuZu3T1FvGnulPg', 'base64').length,
596+
31
597+
);
586598

587599
// This string encodes single '.' character in UTF-16
588600
var dot = new Buffer('//4uAA==', 'base64');

test/parallel/test-cluster-basic.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ var assert = require('assert');
44
var cluster = require('cluster');
55

66
assert.equal('NODE_UNIQUE_ID' in process.env, false,
7-
'NODE_UNIQUE_ID should be removed on startup');
7+
'NODE_UNIQUE_ID should be removed on startup');
88

99
function forEach(obj, fn) {
1010
Object.keys(obj).forEach(function(name, index) {
@@ -93,7 +93,7 @@ else if (cluster.isMaster) {
9393
worker = cluster.fork();
9494
assert.equal(worker.id, 1);
9595
assert.ok(worker instanceof cluster.Worker,
96-
'the worker is not a instance of the Worker constructor');
96+
'the worker is not a instance of the Worker constructor');
9797

9898
//Check event
9999
forEach(checks.worker.events, function(bool, name, index) {

test/parallel/test-crypto-binary-default.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -347,8 +347,11 @@ var a4 = crypto.createHash('sha1').update('Test123').digest('buffer');
347347

348348
if (!common.hasFipsCrypto) {
349349
var a0 = crypto.createHash('md5').update('Test123').digest('binary');
350-
assert.equal(a0, 'h\u00ea\u00cb\u0097\u00d8o\fF!\u00fa+\u000e\u0017\u00ca' +
351-
'\u00bd\u008c', 'Test MD5 as binary');
350+
assert.equal(
351+
a0,
352+
'h\u00ea\u00cb\u0097\u00d8o\fF!\u00fa+\u000e\u0017\u00ca\u00bd\u008c',
353+
'Test MD5 as binary'
354+
);
352355
}
353356

354357
assert.equal(a1, '8308651804facb7b9af8ffc53a33a22d6a1c8ac2', 'Test SHA1');

test/parallel/test-crypto-hash.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,11 @@ a8 = a8.read();
3939

4040
if (!common.hasFipsCrypto) {
4141
var a0 = crypto.createHash('md5').update('Test123').digest('binary');
42-
assert.equal(a0, 'h\u00ea\u00cb\u0097\u00d8o\fF!\u00fa+\u000e\u0017\u00ca' +
43-
'\u00bd\u008c', 'Test MD5 as binary');
42+
assert.equal(
43+
a0,
44+
'h\u00ea\u00cb\u0097\u00d8o\fF!\u00fa+\u000e\u0017\u00ca\u00bd\u008c',
45+
'Test MD5 as binary'
46+
);
4447
}
4548
assert.equal(a1, '8308651804facb7b9af8ffc53a33a22d6a1c8ac2', 'Test SHA1');
4649
assert.equal(a2, '2bX1jws4GYKTlxhloUB09Z66PoJZW+y+hq5R8dnx9l4=',

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ setTimeout(function firstTimer() {
3838
d.dispose();
3939
console.error(err);
4040
console.error('in domain error handler',
41-
process.domain, process.domain === d);
41+
process.domain, process.domain === d);
4242
});
4343

4444
d.run(function() {

test/parallel/test-domain-throw-error-then-throw-from-uncaught-exception-handler.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ function runTestWithoutAbortOnUncaughtException() {
6262
'include domain\'s error\'s message');
6363

6464
assert.notEqual(err.code, 0,
65-
'child process should have exited with a non-zero exit code, ' +
66-
'but did not');
65+
'child process should have exited with a non-zero ' +
66+
'exit code, but did not');
6767
});
6868
}
6969

@@ -72,8 +72,8 @@ function runTestWithAbortOnUncaughtException() {
7272
withAbortOnUncaughtException: true
7373
}), function onTestDone(err, stdout, stderr) {
7474
assert.notEqual(err.code, RAN_UNCAUGHT_EXCEPTION_HANDLER_EXIT_CODE,
75-
'child process should not have run its uncaughtException event ' +
76-
'handler');
75+
'child process should not have run its uncaughtException ' +
76+
'event handler');
7777
assert(common.nodeProcessAborted(err.code, err.signal),
7878
'process should have aborted, but did not');
7979
});

test/parallel/test-domain-timers.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ timeout = setTimeout(function() {}, 10 * 1000);
3434

3535
process.on('exit', function() {
3636
assert.equal(timeout_err.message, 'Timeout UNREFd',
37-
'Domain should catch timer error');
37+
'Domain should catch timer error');
3838
assert.equal(immediate_err.message, 'Immediate Error',
39-
'Domain should catch immediate error');
39+
'Domain should catch immediate error');
4040
});

test/parallel/test-domain-top-level-error-handler-clears-stack.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ d.on('error', common.mustCall(function() {
2323
// call to process._fatalException, and so on recursively and
2424
// indefinitely.
2525
console.error('domains stack length should be 1, but instead is:',
26-
domain._stack.length);
26+
domain._stack.length);
2727
process.exit(1);
2828
}
2929
});

0 commit comments

Comments
 (0)