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: https://github.com/nodejs/node/issues/11650 PR-URL: https://github.com/nodejs/node/pull/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>
This commit is contained in:
parent
02c98f480c
commit
1824bbbff1
@ -6,10 +6,10 @@ if (!common.hasCrypto) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!process.features.tls_alpn) {
|
if (!process.features.tls_alpn || !process.features.tls_npn) {
|
||||||
console.error('Skipping because node compiled without OpenSSL or ' +
|
common.skip('Skipping because node compiled without NPN or ALPN' +
|
||||||
'with old OpenSSL version.');
|
' feature of OpenSSL.');
|
||||||
process.exit(0);
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const assert = require('assert');
|
const assert = require('assert');
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
'use strict';
|
'use strict';
|
||||||
const common = require('../common');
|
const common = require('../common');
|
||||||
if (!process.features.tls_npn) {
|
if (!process.features.tls_npn) {
|
||||||
common.skip('node compiled without OpenSSL or ' +
|
common.skip('Skipping because node compiled without NPN feature of' +
|
||||||
'with old OpenSSL version.');
|
' OpenSSL.');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user