From 3d5726c4adc0a948bb9ef26f7a4b24b45c80a217 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Johan=20Bergstr=C3=B6m?= Date: Wed, 4 Mar 2015 11:36:07 +1100 Subject: [PATCH] test: introduce a helper that checks if crypto is available since this applies to tls and https (among other things), it'll be used for those tests as well. if we decouple the build system to somehow support crypto but not tls, we could refine this. PR-URL: https://github.com/iojs/io.js/pull/1049 Reviewed-By: Ben Noordhuis Reviewed-By: Shigeki Ohtsu --- test/common.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/common.js b/test/common.js index 352f7b6..901425b 100644 --- a/test/common.js +++ b/test/common.js @@ -43,6 +43,9 @@ Object.defineProperty(exports, 'opensslCli', {get: function() { return opensslCli; }, enumerable: true }); +Object.defineProperty(exports, 'hasCrypto', {get: function() { + return process.versions.openssl ? true : false; +}}); if (process.platform === 'win32') { exports.PIPE = '\\\\.\\pipe\\libuv-test'; -- 2.7.4