From b6530ba6a67c8772f36504028bc5f890f852b613 Mon Sep 17 00:00:00 2001 From: Alistair Smith Date: Thu, 8 May 2025 11:16:32 -0700 Subject: [PATCH] 2 more test files --- .../test/parallel/test-tls-cli-max-version-1.2.js | 15 +++++++++++++++ .../test/parallel/test-tls-cli-min-version-1.3.js | 15 +++++++++++++++ 2 files changed, 30 insertions(+) create mode 100644 test/js/node/test/parallel/test-tls-cli-max-version-1.2.js create mode 100644 test/js/node/test/parallel/test-tls-cli-min-version-1.3.js diff --git a/test/js/node/test/parallel/test-tls-cli-max-version-1.2.js b/test/js/node/test/parallel/test-tls-cli-max-version-1.2.js new file mode 100644 index 0000000000..d9887c611e --- /dev/null +++ b/test/js/node/test/parallel/test-tls-cli-max-version-1.2.js @@ -0,0 +1,15 @@ +// Flags: --tls-max-v1.2 +'use strict'; +const common = require('../common'); +if (!common.hasCrypto) common.skip('missing crypto'); + +// Check that node `--tls-max-v1.2` is supported. + +const assert = require('assert'); +const tls = require('tls'); + +assert.strictEqual(tls.DEFAULT_MAX_VERSION, 'TLSv1.2'); +assert.strictEqual(tls.DEFAULT_MIN_VERSION, 'TLSv1.2'); + +// Check the min-max version protocol versions against these CLI settings. +require('./test-tls-min-max-version.js'); \ No newline at end of file diff --git a/test/js/node/test/parallel/test-tls-cli-min-version-1.3.js b/test/js/node/test/parallel/test-tls-cli-min-version-1.3.js new file mode 100644 index 0000000000..5afabe8b3d --- /dev/null +++ b/test/js/node/test/parallel/test-tls-cli-min-version-1.3.js @@ -0,0 +1,15 @@ +// Flags: --tls-min-v1.3 +'use strict'; +const common = require('../common'); +if (!common.hasCrypto) common.skip('missing crypto'); + +// Check that node `--tls-min-v1.3` is supported. + +const assert = require('assert'); +const tls = require('tls'); + +assert.strictEqual(tls.DEFAULT_MAX_VERSION, 'TLSv1.3'); +assert.strictEqual(tls.DEFAULT_MIN_VERSION, 'TLSv1.3'); + +// Check the min-max version protocol versions against these CLI settings. +require('./test-tls-min-max-version.js'); \ No newline at end of file