Skip to content

Commit

Permalink
test: remove extraneous report validation argument
Browse files Browse the repository at this point in the history
The second argument passed to validate() and validateContent()
is not used for anything.

PR-URL: #25986
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
  • Loading branch information
cjihrig authored and targos committed Feb 10, 2019
1 parent 29c195e commit d123f94
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 30 deletions.
5 changes: 1 addition & 4 deletions test/node-report/test-api-getreport.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,5 @@ if (process.argv[2] === 'child') {
' experimental feature. This feature could change at any time'), std_msg);
const reportFiles = helper.findReports(child.pid, tmpdir.path);
assert.deepStrictEqual(reportFiles, [], report_msg);
helper.validateContent(child.stdout, { pid: child.pid,
commandline: process.execPath +
' ' + args.join(' ')
});
helper.validateContent(child.stdout);
}
4 changes: 1 addition & 3 deletions test/node-report/test-api-nohooks.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@ if (process.argv[2] === 'child') {
const reports = helper.findReports(child.pid, tmpdir.path);
assert.strictEqual(reports.length, 1, report_msg);
const report = reports[0];
helper.validate(report, { pid: child.pid,
commandline: child.spawnargs.join(' ')
});
helper.validate(report);
}));
}
5 changes: 1 addition & 4 deletions test/node-report/test-api-pass-error.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ if (process.argv[2] === 'child') {
const reports = helper.findReports(child.pid, tmpdir.path);
assert.strictEqual(reports.length, 1, report_msg);
const report = reports[0];
helper.validate(report, { pid: child.pid,
commandline: child.spawnargs.join(' '),
expectedException: 'Testing error handling',
});
helper.validate(report);
}));
}
4 changes: 1 addition & 3 deletions test/node-report/test-api-uvhandles.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,6 @@ if (process.argv[2] === 'child') {
assert.deepStrictEqual(udp, 1, udp_msg);

// Common report tests.
helper.validateContent(stdout, { pid: child.pid,
commandline: child.spawnargs.join(' ')
});
helper.validateContent(stdout);
}));
}
4 changes: 1 addition & 3 deletions test/node-report/test-api.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ if (process.argv[2] === 'child') {
const reports = helper.findReports(child.pid, tmpdir.path);
assert.strictEqual(reports.length, 1, report_msg);
const report = reports[0];
helper.validate(report, { pid: child.pid,
commandline: child.spawnargs.join(' ')
});
helper.validate(report);
}));
}
4 changes: 1 addition & 3 deletions test/node-report/test-exception.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ if (process.argv[2] === 'child') {
const reports = helper.findReports(child.pid, tmpdir.path);
assert.strictEqual(reports.length, 1, report_msg);
const report = reports[0];
helper.validate(report, { pid: child.pid,
commandline: child.spawnargs.join(' ')
});
helper.validate(report);
}));
}
8 changes: 1 addition & 7 deletions test/node-report/test-fatal-error.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,6 @@ if (process.argv[2] === 'child') {
const reports = helper.findReports(child.pid, tmpdir.path);
assert.strictEqual(reports.length, 1);
const report = reports[0];
const options = { pid: child.pid };
// Node.js currently overwrites the command line on AIX
// https://github.com/nodejs/node/issues/10607
if (!(common.isAIX || common.isSunOS)) {
options.commandline = child.spawnargs.join(' ');
}
helper.validate(report, options);
helper.validate(report);
}));
}
4 changes: 1 addition & 3 deletions test/node-report/test-signal.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ if (process.argv[2] === 'child') {
const reports = helper.findReports(child.pid, tmpdir.path);
assert.deepStrictEqual(reports.length, 1, report_msg);
const report = reports[0];
helper.validate(report, { pid: child.pid,
commandline: child.spawnargs.join(' ')
});
helper.validate(report);
}));
}

0 comments on commit d123f94

Please sign in to comment.