Skip to content

Commit

Permalink
test: replace function with arrow function
Browse files Browse the repository at this point in the history
Replace some classic functions with arrow functions in
test-child-process-send-cb.js

PR-URL: #17312
Reviewed-By: Ron Korving <[email protected]>
Reviewed-By: Vse Mozhet Byt <[email protected]>
Reviewed-By: Michaël Zasso <[email protected]>
Reviewed-By: Daijiro Wachi <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: Jon Moss <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
spring_raining authored and MylesBorins committed Dec 12, 2017
1 parent 120d756 commit 97a279e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/parallel/test-child-process-send-cb.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ const assert = require('assert');
const fork = require('child_process').fork;

if (process.argv[2] === 'child') {
process.send('ok', common.mustCall(function(err) {
process.send('ok', common.mustCall((err) => {
assert.strictEqual(err, null);
}));
} else {
const child = fork(process.argv[1], ['child']);
child.on('message', common.mustCall(function(message) {
child.on('message', common.mustCall((message) => {
assert.strictEqual(message, 'ok');
}));
child.on('exit', common.mustCall(function(exitCode, signalCode) {
child.on('exit', common.mustCall((exitCode, signalCode) => {
assert.strictEqual(exitCode, 0);
assert.strictEqual(signalCode, null);
}));
Expand Down

0 comments on commit 97a279e

Please sign in to comment.