Fix Windows smoke relay launch

This commit is contained in:
Mohamed Boudra
2026-03-10 19:43:30 +07:00
parent f09b43eef0
commit e1f4e6fafb
@@ -487,10 +487,17 @@ let externalPid = null;
let startedTemporaryExternalDaemon = false;
let relayProcess = null;
const forbiddenManagedReferences = ["127.0.0.1:6767", fakePaseoHome, managedRuntimeDir];
const npmExecPath = process.env.npm_execpath;
if (!npmExecPath) {
throw new Error("npm_execpath is required to launch wrangler during managed desktop smoke tests.");
}
try {
logStep(`Starting isolated local relay on ${relayEndpoint}`);
relayProcess = spawn(process.platform === "win32" ? "npx.cmd" : "npx", [
relayProcess = spawn(process.execPath, [
npmExecPath,
"exec",
"--",
"wrangler",
"dev",
"--local",