()
| 11 | const { NodeInstance } = require('../common/inspector-helper.js'); |
| 12 | |
| 13 | async function runTest() { |
| 14 | const main = fixtures.path('es-module-loaders', 'register-loader.mjs'); |
| 15 | process.env.NODE_DEBUG = 'esm,async_loader_worker'; |
| 16 | const child = new NodeInstance(['--inspect-wait=0'], '', main); |
| 17 | |
| 18 | const session = await child.connectInspectorSession(); |
| 19 | await session.send({ method: 'NodeRuntime.enable' }); |
| 20 | await session.waitForNotification('NodeRuntime.waitingForDebugger'); |
| 21 | await session.send([ |
| 22 | { 'method': 'Runtime.enable' }, |
| 23 | { 'method': 'Debugger.enable' }, |
| 24 | { 'method': 'Runtime.runIfWaitingForDebugger' }, |
| 25 | ]); |
| 26 | await session.send({ method: 'NodeRuntime.disable' }); |
| 27 | await session.waitForDisconnect(); |
| 28 | const result = await child.expectShutdown(); |
| 29 | assert.deepStrictEqual(result, { |
| 30 | exitCode: 0, |
| 31 | signal: null, |
| 32 | }); |
| 33 | } |
| 34 | |
| 35 | runTest(); |
no test coverage detected
searching dependent graphs…