Skip to content

Commit 7cc4645

Browse files
shigekiMylesBorins
authored andcommitted
test: fix tests when npn feature is disabled.
ALPN test needs NPN feature to run. It also change the messages when ALPN and NPN tests are skipped. Fixes: #11650 PR-URL: #11655 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Fedor Indutny <fedor@indutny.com>
1 parent b1ddf11 commit 7cc4645

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

test/parallel/test-tls-alpn-server-client.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ if (!common.hasCrypto) {
66
return;
77
}
88

9-
if (!process.features.tls_alpn) {
10-
console.error('Skipping because node compiled without OpenSSL or ' +
11-
'with old OpenSSL version.');
12-
process.exit(0);
9+
if (!process.features.tls_alpn || !process.features.tls_npn) {
10+
common.skip('Skipping because node compiled without NPN or ALPN' +
11+
' feature of OpenSSL.');
12+
return;
1313
}
1414

1515
const assert = require('assert');

test/parallel/test-tls-npn-server-client.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
'use strict';
22
if (!process.features.tls_npn) {
3-
common.skip('node compiled without OpenSSL or ' +
4-
'with old OpenSSL version.');
3+
common.skip('Skipping because node compiled without NPN feature of' +
4+
' OpenSSL.');
55
return;
66
}
77

0 commit comments

Comments
 (0)