Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorSakthipriyan Vairamani (thefourtheye) <thechargingvolcano@gmail.com>2017-02-27 21:45:58 +0300
committerEvan Lucas <evanlucas@me.com>2017-03-07 15:04:05 +0300
commitfdb4a6c796b2220731c6365f7effa7c03d88fde6 (patch)
tree8e2379817b7276fab35868231f0345ed0fa4d7aa /test
parented6d7412a74bbbf612b138b41f2432a089f21b34 (diff)
test: skip the test with proper TAP message
On Windows, the test simply returns which will be counted as passed. The test actually skips the rest of the test. So proper TAP message has to be included while skipping. This patch uses `common.skip` rather than `console.log` to print the skip messages. PR-URL: https://github.com/nodejs/node/pull/11584 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Diffstat (limited to 'test')
-rw-r--r--test/parallel/test-setproctitle.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/parallel/test-setproctitle.js b/test/parallel/test-setproctitle.js
index a971d604b37..072ddd447e5 100644
--- a/test/parallel/test-setproctitle.js
+++ b/test/parallel/test-setproctitle.js
@@ -4,8 +4,7 @@ const common = require('../common');
// FIXME add sunos support
if (common.isSunOS) {
- console.log(`1..0 # Skipped: Unsupported platform [${process.platform}]`);
- return;
+ return common.skip(`Unsupported platform [${process.platform}]`);
}
const assert = require('assert');
@@ -22,8 +21,9 @@ process.title = title;
assert.strictEqual(process.title, title);
// Test setting the title but do not try to run `ps` on Windows.
-if (common.isWindows)
- return;
+if (common.isWindows) {
+ return common.skip('Windows does not have "ps" utility');
+}
exec(`ps -p ${process.pid} -o args=`, function callback(error, stdout, stderr) {
assert.ifError(error);