Skip to content

Commit

Permalink
test: add mustCall() to child-process test
Browse files Browse the repository at this point in the history
Add common.mustCall() check to test-child-process-stdio-big-write-end.

PR-URL: #13605
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Yuta Hiroto <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
Trott authored and MylesBorins committed Aug 16, 2017
1 parent 406b3c0 commit 9356e96
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/parallel/test-child-process-stdio-big-write-end.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
'use strict';
require('../common');
const common = require('../common');
const assert = require('assert');
let bufsize = 0;

Expand All @@ -22,10 +22,10 @@ function parent() {
child.stdout.on('data', function(c) {
n += c;
});
child.stdout.on('end', function() {
child.stdout.on('end', common.mustCall(function() {
assert.strictEqual(+n, sent);
console.log('ok');
});
}));

// Write until the buffer fills up.
let buf;
Expand Down

0 comments on commit 9356e96

Please sign in to comment.