Skip to content

Commit b6c30e1

Browse files
cjihrigMylesBorins
authored andcommitted
test: fix broken assertion
This commit fixes a broken assertion in test-cli-eval.js. PR-URL: #10840 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
1 parent 4d6b484 commit b6c30e1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

test/parallel/test-cli-eval.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,8 @@ child.exec(nodejs + ' --eval "require(\'./test/parallel/test-cli-eval.js\')"',
8181
child.exec(nodejs + ' -e', common.mustCall(function(err, stdout, stderr) {
8282
assert.strictEqual(err.code, 9);
8383
assert.strictEqual(stdout, '');
84-
assert(stderr.match(/node: -e requires an argument\n/));
84+
assert.strictEqual(stderr.trim(),
85+
`${process.execPath}: -e requires an argument`);
8586
}));
8687

8788
// empty program should do nothing

0 commit comments

Comments
 (0)