mirror of
https://github.com/nodejs/node.git
synced 2024-12-01 16:10:02 +01:00
test: add mustCall() to child-process test
Add common.mustCall() check to test-child-process-stdio-big-write-end. PR-URL: https://github.com/nodejs/node/pull/13605 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
parent
c88ba036b4
commit
f308b4d9ed
@ -20,7 +20,7 @@
|
||||
// USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
'use strict';
|
||||
require('../common');
|
||||
const common = require('../common');
|
||||
const assert = require('assert');
|
||||
let bufsize = 0;
|
||||
|
||||
@ -43,10 +43,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;
|
||||
|
Loading…
Reference in New Issue
Block a user