Skip to content

Commit 5efe4f7

Browse files
joyeecheungaduh95
authored andcommitted
test: add more logs to test-esm-loader-hooks-inspect-wait
This provides a bit more information about where & when the child processes crashes when it crashes / flakes in the CI. PR-URL: #60466 Refs: #54346 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
1 parent 2a57268 commit 5efe4f7

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

‎test/parallel/test-esm-loader-hooks-inspect-wait.js‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ const { NodeInstance } = require('../common/inspector-helper.js');
1212

1313
asyncfunctionrunTest(){
1414
constmain=fixtures.path('es-module-loaders','register-loader.mjs');
15+
process.env.NODE_DEBUG='esm,async_loader_worker';
1516
constchild=newNodeInstance(['--inspect-wait=0'],'',main);
1617

1718
constsession=awaitchild.connectInspectorSession();
@@ -24,7 +25,11 @@ async function runTest() {
2425
]);
2526
awaitsession.send({method: 'NodeRuntime.disable'});
2627
awaitsession.waitForDisconnect();
27-
assert.strictEqual((awaitchild.expectShutdown()).exitCode,0);
28+
constresult=awaitchild.expectShutdown();
29+
assert.deepStrictEqual(result,{
30+
exitCode: 0,
31+
signal: null,
32+
});
2833
}
2934

3035
runTest();

0 commit comments

Comments
 (0)