From 0322d3b8d5369b3316bd632fd4d23bc12e548c41 Mon Sep 17 00:00:00 2001 From: "Sakthipriyan Vairamani (thefourtheye)" Date: Tue, 28 Feb 2017 00:24:03 +0530 Subject: [PATCH] test: skip tests with common.skip The `common.skip` function adds proper message in TAP format to skipped tests. It is better not to have the message rewritten in the tests. PR-URL: https://github.com/nodejs/node/pull/11585 Reviewed-By: Colin Ihrig Reviewed-By: James M Snell Reviewed-By: Gibson Fahnestock Reviewed-By: Luigi Pinca Reviewed-By: Yuta Hiroto --- test/parallel/test-crypto-authenticated.js | 2 +- test/parallel/test-tls-empty-sni-context.js | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/test/parallel/test-crypto-authenticated.js b/test/parallel/test-crypto-authenticated.js index 245783fb1b4275..1a628023b5c46e 100644 --- a/test/parallel/test-crypto-authenticated.js +++ b/test/parallel/test-crypto-authenticated.js @@ -318,7 +318,7 @@ for (const i in TEST_CASES) { } if (common.hasFipsCrypto && test.iv.length < 24) { - console.log('1..0 # Skipped: IV len < 12 bytes unsupported in FIPS mode'); + common.skip('IV len < 12 bytes unsupported in FIPS mode'); continue; } diff --git a/test/parallel/test-tls-empty-sni-context.js b/test/parallel/test-tls-empty-sni-context.js index 52e9f14b64d91a..9e022c9c6a8804 100644 --- a/test/parallel/test-tls-empty-sni-context.js +++ b/test/parallel/test-tls-empty-sni-context.js @@ -3,16 +3,14 @@ const common = require('../common'); if (!process.features.tls_sni) { - console.log('1..0 # Skipped: node compiled without OpenSSL or ' + - 'with old OpenSSL version.'); + common.skip('node compiled without OpenSSL or with old OpenSSL version.'); return; } const assert = require('assert'); if (!common.hasCrypto) { - console.log('1..0 # Skipped: missing crypto'); - return; + return common.skip('missing crypto'); } const tls = require('tls');