diff --git a/src/infra/process-respawn.test.ts b/src/infra/process-respawn.test.ts index 89e64d401ab..3421b918743 100644 --- a/src/infra/process-respawn.test.ts +++ b/src/infra/process-respawn.test.ts @@ -155,10 +155,11 @@ describe("restartGatewayProcessWithFreshPid", () => { expect(spawnMock).toHaveBeenCalledWith( process.execPath, ["--import", "tsx", "/repo/dist/index.js", "gateway", "run"], - expect.objectContaining({ + { detached: true, + env: process.env, stdio: "inherit", - }), + }, ); }); @@ -286,11 +287,11 @@ describe("respawnGatewayProcessForUpdate", () => { expect(spawnMock).toHaveBeenCalledWith( process.execPath, ["C:\\openclaw\\dist\\index.js", "gateway", "run"], - expect.objectContaining({ + { detached: true, env: process.env, stdio: "inherit", - }), + }, ); }); });