Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update test/parallel/test-experimental-shared-value-conveyor.js
Co-authored-by: Joyee Cheung <joyeec9h3@gmail.com>
  • Loading branch information
syg and joyeecheung authored May 5, 2023
commit eeaf8430481a9e908e12e308d0dde84cbe260d36
4 changes: 3 additions & 1 deletion test/parallel/test-experimental-shared-value-conveyor.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@ const common = require('../common');
const assert = require('assert');
const { Worker, isMainThread, parentPort } = require('worker_threads');

if (isMainThread) {
// Do not use isMainThread so that this test itself can be run inside a Worker.
if (!process.env.HAS_STARTED_WORKER) {
process.env.HAS_STARTED_WORKER = 1;
const m = new globalThis.SharedArray(16);

const worker = new Worker(__filename);
Expand Down