mirror of
https://github.com/nodejs/node.git
synced 2025-05-02 16:22:29 +00:00

Instead of using process.config.variables.v8_enable_inspector to detect whether inspector is enabled in the build. PR-URL: https://github.com/nodejs/node/pull/25819 Refs: https://github.com/nodejs/node/issues/25343 Reviewed-By: Eugene Ostroukhov <eostroukhov@google.com> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
16 lines
338 B
JavaScript
16 lines
338 B
JavaScript
// Flags: --expose-internals
|
|
'use strict';
|
|
|
|
const common = require('../common');
|
|
|
|
if (process.features.inspector) {
|
|
common.skip('V8 inspector is enabled');
|
|
}
|
|
|
|
const inspector = require('internal/util/inspector');
|
|
|
|
inspector.sendInspectorCommand(
|
|
common.mustNotCall('Inspector callback should not be called'),
|
|
common.mustCall(1),
|
|
);
|