tools: fix inspector-check reporting
Currently the inspector-check rule does not store the node when the
usage of a require('inspector') is done. This means that it is not
possible to disable this rule. For example, if you add the following to
a test that uses the inspector module:
//common.skipIfInspectorDisabled();
/* eslint-disable inspector-check */
This will not disable the check and there will still be a lint error
reported.
This commit stores the node where the require statement is done which
allows for the rule to also be disabled.
PR-URL: https://github.com/nodejs/node/pull/16902
Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By:
James M Snell <jasnell@gmail.com>
Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
parent
8215c671
Please register or sign in to comment