Skip to content

Commit 456f76a

Browse files
Trottaddaleax
authored andcommitted
test: remove flag for test-addon-uv-handle-leak
test-addon-uv-handle-leak only requires worker_threads for the subprocess which it explicitly calls with --experimental-worker. The main test itself does not need it. Remove Flags: comment and move loading of worker_threads into subprocess-only logic. PR-URL: #25327 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent 523872b commit 456f76a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/abort/test-addon-uv-handle-leak.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
1-
// Flags: --experimental-worker
21
'use strict';
32
const common = require('../common');
43
const assert = require('assert');
54
const fs = require('fs');
65
const path = require('path');
76
const cp = require('child_process');
8-
const { Worker } = require('worker_threads');
97
const { spawnSync } = require('child_process');
108

119
// This is a sibling test to test/addons/uv-handle-leak.
@@ -19,6 +17,8 @@ if (!fs.existsSync(bindingPath))
1917

2018
if (process.argv[2] === 'child') {
2119

20+
const { Worker } = require('worker_threads');
21+
2222
// The worker thread loads and then unloads `bindingPath`. Because of this the
2323
// symbols in `bindingPath` are lost when the worker thread quits, but the
2424
// number of open handles in the worker thread's event loop is assessed in the

0 commit comments

Comments
 (0)