Skip to content

Commit 8b0a780

Browse files
danbevMylesBorins
authored andcommitted
test: skipIfInspectorDisabled cluster-inspect-brk
When configured --without-ssl the inspect-brk option will not be available and the process will exit with a exit value of 9 "Invalid Argument/Bad option". This commit adds a skipIfInspectorDisabled check since --without-ssl implies that no inspector support is build as well. PR-URL: #12757 Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Michaël Zasso <[email protected]> Reviewed-By: James M Snell <[email protected]>
1 parent 1de5797 commit 8b0a780

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

test/common/index.js

+7
Original file line numberDiff line numberDiff line change
@@ -575,3 +575,10 @@ exports.crashOnUnhandledRejection = function() {
575575
process.on('unhandledRejection',
576576
(err) => process.nextTick(() => { throw err; }));
577577
};
578+
579+
exports.skipIfInspectorDisabled = function skipIfInspectorDisabled() {
580+
if (!exports.hasCrypto) {
581+
exports.skip('missing ssl support so inspector is disabled');
582+
process.exit(0);
583+
}
584+
};

test/sequential/test-cluster-inspect-brk.js

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
'use strict';
22
const common = require('../common');
3+
common.skipIfInspectorDisabled();
34

45
// A test to ensure that cluster properly interoperates with the
56
// --inspect-brk option.

0 commit comments

Comments
 (0)