From 2a811ea1a9b93ee2996b7cf69eeb191242d805fe Mon Sep 17 00:00:00 2001 From: Devin Foley Date: Fri, 2 Oct 2026 17:33:49 -0700 Subject: [PATCH] test: forward stdin through the Cursor fixture runner Co-Authored-By: Paperclip --- packages/adapters/cursor-local/src/server/execute.test.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/adapters/cursor-local/src/server/execute.test.ts b/packages/adapters/cursor-local/src/server/execute.test.ts index 913d34cdc40..6aea2414d3d 100644 --- a/packages/adapters/cursor-local/src/server/execute.test.ts +++ b/packages/adapters/cursor-local/src/server/execute.test.ts @@ -288,7 +288,7 @@ printf '%s\\n' '{"type":"result","subtype":"success","session_id":"cursor-sessio finalPreparedCommand = preferredCommandPath; const runtimeEnv = { ...input.env, - PATH: `${path.join(systemHomeDir, ".local", "bin")}${path.delimiter}${input.env.PATH}`, + PATH: `${path.join(systemHomeDir, ".local", "bin")}${path.delimiter}${input.env.PATH ?? process.env.PATH ?? "/usr/bin:/bin"}`, }; await fs.mkdir(path.dirname(preferredCommandPath), { recursive: true }); await fs.writeFile(preferredCommandPath, preferredAgentScript); @@ -312,13 +312,14 @@ printf '%s\\n' '{"type":"result","subtype":"success","session_id":"cursor-sessio // shell seam faithful to that protocol instead of returning empty stdout // for every shell command. const runner = { - execute: async (input: { command: string; args?: string[]; env?: Record }) => { + execute: async (input: { command: string; args?: string[]; env?: Record; stdin?: string }) => { runnerState.commands.push(input.command); // Exercise actual bounded file reads during managed-home restoration; // reporting empty success for every shell command hides missing bytes. return runChildProcess(`cursor-fresh-lease-${runnerState.commands.length}`, input.command, input.args ?? [], { cwd: remoteWorkspace, env: { ...input.env, PATH: `${input.env?.PATH ?? ""}:/usr/bin:/bin` }, + stdin: input.stdin, timeoutSec: 30, graceSec: 5, onLog: async () => {},