summaryrefslogtreecommitdiff
path: root/cli/tests/workers_round_robin_bench.ts
diff options
context:
space:
mode:
Diffstat (limited to 'cli/tests/workers_round_robin_bench.ts')
-rw-r--r--cli/tests/workers_round_robin_bench.ts5
1 files changed, 4 insertions, 1 deletions
diff --git a/cli/tests/workers_round_robin_bench.ts b/cli/tests/workers_round_robin_bench.ts
index c7a683459..d7224b41d 100644
--- a/cli/tests/workers_round_robin_bench.ts
+++ b/cli/tests/workers_round_robin_bench.ts
@@ -37,7 +37,10 @@ function handleAsyncMsgFromWorker(
async function main(): Promise<void> {
const workers: Array<[Map<number, Resolvable<string>>, Worker]> = [];
for (let i = 1; i <= workerCount; ++i) {
- const worker = new Worker("./subdir/bench_worker.ts", { type: "module" });
+ const worker = new Worker(
+ new URL("subdir/bench_worker.ts", import.meta.url).href,
+ { type: "module" }
+ );
const promise = createResolvable<void>();
worker.onmessage = (e): void => {
if (e.data.cmdId === 0) promise.resolve();