MCPcopy Index your code
hub / github.com/nodejs/node / test

Function test

test/parallel/test-inspector-ip-detection.js:32–44  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

30}
31
32async function test() {
33 const instance = new NodeInstance('--inspect-brk=0.0.0.0:0');
34 try {
35 checkIpAddress(ip, await instance.httpGet(ip, '/json/list'));
36 } catch (error) {
37 if (error.code === 'EHOSTUNREACH') {
38 common.printSkipMessage('Unable to connect to self');
39 } else {
40 throw error;
41 }
42 }
43 instance.kill();
44}
45
46test().then(common.mustCall());

Callers 1

Calls 3

httpGetMethod · 0.95
killMethod · 0.95
checkIpAddressFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…