test: fix test-debugger-profile for coverage generation

The child process should not inherit NODE_V8_COVERAGE because
that clobbers the inspector output the test is checking.

PR-URL: https://github.com/nodejs/node/pull/51816
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev>
This commit is contained in:
Joyee Cheung authored and Node.js GitHub Bot committed 2024-02-25 18:25:38 +00:00
1 parent 765baa7a0b
commit 1353a7b1f7
1 file changed
+8 -1
+8 -1
View File
@@ -14,7 +14,14 @@ function delay(ms) {
// Profiles.
{
const cli = startCLI(['--port=0', fixtures.path('debugger/empty.js')]);
const cli = startCLI(['--port=0', fixtures.path('debugger/empty.js')], [], {
env: {
...process.env,
// When this test is run with NODE_V8_COVERAGE, it clobbers the inspector
// output, so override to disable coverage for the child process.
NODE_V8_COVERAGE: undefined,
}
});
function onFatal(error) {
cli.quit();