From 19a432260cd2a2981c067c88f37f71206d23ccd2 Mon Sep 17 00:00:00 2001 From: Ben Noordhuis Date: Tue, 4 Sep 2012 14:40:59 +0200 Subject: [PATCH] test: add extra checks in simple/test-cli-eval --- test/simple/test-cli-eval.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/simple/test-cli-eval.js b/test/simple/test-cli-eval.js index eb619e1d50..acb85d4caa 100644 --- a/test/simple/test-cli-eval.js +++ b/test/simple/test-cli-eval.js @@ -39,11 +39,13 @@ var filename = __filename.replace(/\\/g, '/'); child.exec(nodejs + ' --eval 42', function(err, stdout, stderr) { assert.equal(stdout, ''); + assert.equal(stderr, ''); }); // assert that "42\n" is written to stderr child.exec(nodejs + ' --eval "console.error(42)"', function(err, stdout, stderr) { + assert.equal(stdout, ''); assert.equal(stderr, '42\n'); }); @@ -54,11 +56,13 @@ child.exec(nodejs + ' --eval "console.error(42)"', child.exec(cmd + '42', function(err, stdout, stderr) { assert.equal(stdout, '42\n'); + assert.equal(stderr, ''); }); child.exec(cmd + "'[]'", function(err, stdout, stderr) { assert.equal(stdout, '[]\n'); + assert.equal(stderr, ''); }); }); @@ -84,4 +88,5 @@ child.exec(nodejs + ' -e ""', function(status, stdout, stderr) { child.exec(nodejs + ' -p "\\-42"', function(err, stdout, stderr) { assert.equal(stdout, '-42\n'); + assert.equal(stderr, ''); });