test: refactor test-stdin-from-file
Remove console.log statement. Replace error check with assert.ifError(). PR-URL: https://github.com/nodejs/node/pull/10331 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
parent
4c9dd6822e
commit
407c1ad66c
@ -33,8 +33,7 @@ fs.writeFileSync(tmpFile, string);
|
||||
childProcess.exec(cmd, common.mustCall(function(err, stdout, stderr) {
|
||||
fs.unlinkSync(tmpFile);
|
||||
|
||||
if (err) throw err;
|
||||
console.log(stdout);
|
||||
assert.ifError(err);
|
||||
assert.strictEqual(stdout, 'hello world\r\n' + string);
|
||||
assert.strictEqual('', stderr);
|
||||
}));
|
||||
|
Loading…
x
Reference in New Issue
Block a user