From efd1b78e823b2fb4afab4f848a6ebad8d44f46ea Mon Sep 17 00:00:00 2001 From: Matheus Marchini Date: Fri, 6 Mar 2020 16:13:00 -0800 Subject: [PATCH] test: warn when inspector process crashes If the subprocess being inspected hard crashes, there will be no information on the log, and the parent process will just wait until timeout. Logging the error signal when it happens can help developers understand failures faster. Signed-off-by: Matheus Marchini --- test/common/inspector-helper.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/common/inspector-helper.js b/test/common/inspector-helper.js index 42d6baed4410de..d430137746dd81 100644 --- a/test/common/inspector-helper.js +++ b/test/common/inspector-helper.js @@ -344,6 +344,9 @@ class NodeInstance extends EventEmitter { this._shutdownPromise = new Promise((resolve) => { this._process.once('exit', (exitCode, signal) => { + if (signal) { + console.error(`[err] child process crashed, signal ${signal}`); + } resolve({ exitCode, signal }); this._running = false; });