diff --git a/packages/coding-agent/test/advisor/advisor.test.ts b/packages/coding-agent/test/advisor/advisor.test.ts index 0c37f905f..44063d3f4 100644 --- a/packages/coding-agent/test/advisor/advisor.test.ts +++ b/packages/coding-agent/test/advisor/advisor.test.ts @@ -3837,7 +3837,7 @@ describe("advisor", () => { }); it("asks the host to switch models when a refusal outlives the stripped resend", async () => { - const promptInputs: string[] = []; + const promptInputs: Array = []; const failures: unknown[] = []; const state: { messages: AgentMessage[]; error?: string } = { messages: [] }; // The first model refuses every time; the host's fallback hook swaps in a @@ -3910,7 +3910,7 @@ describe("advisor", () => { }); it("starts a fresh fallback cascade after the host declines to switch models", async () => { - const promptInputs: string[] = []; + const promptInputs: Array = []; const failures: unknown[] = []; let fallbackCalls = 0; const state: { messages: AgentMessage[]; error?: string } = { messages: [] }; @@ -3983,7 +3983,7 @@ describe("advisor", () => { it("walks the whole fallback chain before reporting a refusal", async () => { // Every model refuses. The cascade must reach the last chain entry, then // stop once the host runs out of candidates. - const promptInputs: string[] = []; + const promptInputs: Array = []; const failures: unknown[] = []; const state: { messages: AgentMessage[]; error?: string } = { messages: [] }; let identity = "anthropic/claude-fable-5"; @@ -4046,7 +4046,7 @@ describe("advisor", () => { }); it("stops a refusal walk that a cyclic chain would loop forever", async () => { - const promptInputs: string[] = []; + const promptInputs: Array = []; const failures: unknown[] = []; const state: { messages: AgentMessage[]; error?: string } = { messages: [] }; // A chain configured A -> B -> A: the host never runs out of candidates, diff --git a/packages/coding-agent/test/cursor-exec.test.ts b/packages/coding-agent/test/cursor-exec.test.ts index 4d7246fce..50929d247 100644 --- a/packages/coding-agent/test/cursor-exec.test.ts +++ b/packages/coding-agent/test/cursor-exec.test.ts @@ -706,11 +706,12 @@ describe("CursorExecHandlers error results", () => { // present-undefined and ArkType rejects the bash call. const events: AgentEvent[] = []; const executeArgs: Record[] = []; - const bashTool: AgentTool = { + const bashSchema = type({ command: "string", "cwd?": "string", "timeout?": "number" }); + const bashTool: AgentTool = { name: "bash", label: "bash", description: "records args", - parameters: type({ command: "string", "cwd?": "string", "timeout?": "number" }), + parameters: bashSchema, execute: async (_id, args) => { executeArgs.push({ ...args }); return { content: [{ type: "text", text: "ok" }], details: {} };