Tests: disable vmForks on Node 24 and document override

This commit is contained in:
Sebastian
2026-02-13 08:15:25 -05:00
parent 94763cd87d
commit 5d37b204c0
3 changed files with 8 additions and 1 deletions

View File

@@ -32,9 +32,11 @@ const isCI = process.env.CI === "true" || process.env.GITHUB_ACTIONS === "true";
const isMacOS = process.platform === "darwin" || process.env.RUNNER_OS === "macOS";
const isWindows = process.platform === "win32" || process.env.RUNNER_OS === "Windows";
const isWindowsCi = isCI && isWindows;
const nodeMajor = Number.parseInt(process.versions.node.split(".")[0] ?? "", 10);
const supportsVmForks = Number.isFinite(nodeMajor) ? nodeMajor < 24 : true;
const useVmForks =
process.env.OPENCLAW_TEST_VM_FORKS === "1" ||
(process.env.OPENCLAW_TEST_VM_FORKS !== "0" && !isWindows);
(process.env.OPENCLAW_TEST_VM_FORKS !== "0" && !isWindows && supportsVmForks);
const runs = [
...(useVmForks
? [