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.
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
commit message follows commit guidelines
Affected core subsystem(s)
tools