From 97a279e375bc079eef9809c18daebab3d9328203 Mon Sep 17 00:00:00 2001 From: spring_raining Date: Sun, 26 Nov 2017 17:45:11 +0900 Subject: [PATCH] test: replace function with arrow function MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace some classic functions with arrow functions in test-child-process-send-cb.js PR-URL: https://github.com/nodejs/node/pull/17312 Reviewed-By: Ron Korving Reviewed-By: Vse Mozhet Byt Reviewed-By: Michaƫl Zasso Reviewed-By: Daijiro Wachi Reviewed-By: Luigi Pinca Reviewed-By: Gireesh Punathil Reviewed-By: Jon Moss Reviewed-By: James M Snell --- test/parallel/test-child-process-send-cb.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/parallel/test-child-process-send-cb.js b/test/parallel/test-child-process-send-cb.js index d65a1abd204a04..daecd722533f57 100644 --- a/test/parallel/test-child-process-send-cb.js +++ b/test/parallel/test-child-process-send-cb.js @@ -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); }));