From e80870a593a3590d8c313ec65da35807ab89e0a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alejandro=20L=C3=B3pez?= Date: Sun, 14 Oct 2018 00:24:03 +0200 Subject: [PATCH] ci summary: change `console.error` for `console.log` --- lib/ci.js | 2 +- test/tap/ci.js | 10 ++++------ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/lib/ci.js b/lib/ci.js index e71d89cfddb2f..03822b9528d1d 100644 --- a/lib/ci.js +++ b/lib/ci.js @@ -31,7 +31,7 @@ function ci (args, cb) { .then( (details) => { npmlog.disableProgress() - console.error(`added ${details.pkgCount} packages in ${ + console.log(`added ${details.pkgCount} packages in ${ details.runTime / 1000 }s`) } diff --git a/test/tap/ci.js b/test/tap/ci.js index a523f87623aa3..9d69e3e5eb524 100644 --- a/test/tap/ci.js +++ b/test/tap/ci.js @@ -83,9 +83,9 @@ test('basic installation', (t) => { const stdout = ret[1] const stderr = ret[2] t.equal(code, 0, 'command completed without error') - t.equal(stdout.trim(), '', 'no output on stdout') + t.equal(stderr.trim(), '', 'no output on stderr') t.match( - stderr.trim(), + stdout.trim(), /^added 6 packages in \d+(?:\.\d+)?s$/, 'no warnings on stderr, and final output has right number of packages' ) @@ -150,9 +150,9 @@ test('supports npm-shrinkwrap.json as well', (t) => { const stdout = ret[1] const stderr = ret[2] t.equal(code, 0, 'command completed without error') - t.equal(stdout.trim(), '', 'no output on stdout') + t.equal(stderr.trim(), '', 'no output on stderr') t.match( - stderr.trim(), + stdout.trim(), /^added 6 packages in \d+(?:\.\d+)?s$/, 'no warnings on stderr, and final output has right number of packages' ) @@ -197,10 +197,8 @@ test('removes existing node_modules/ before installing', (t) => { ], EXEC_OPTS)) .then((ret) => { const code = ret[0] - const stdout = ret[1] const stderr = ret[2] t.equal(code, 0, 'command completed without error') - t.equal(stdout.trim(), '', 'no output on stdout') t.match( stderr.trim(), /^npm.*WARN.*removing existing node_modules/,