(session: McpSession, code: string)
| 114 | |
| 115 | /** Run the agent tool and approve its catalog-changing action. */ |
| 116 | const executeJson = (session: McpSession, code: string) => |
| 117 | Effect.gen(function* () { |
| 118 | let result = yield* session.call("execute", { code }); |
| 119 | let guard = 0; |
| 120 | while (result.text.includes("executionId:") && guard < 10) { |
| 121 | result = yield* session.approvePaused(result.text); |
| 122 | guard += 1; |
| 123 | } |
| 124 | expect(result.ok, `execute completed (got: ${result.text.slice(0, 400)})`).toBe(true); |
| 125 | return JSON.parse(result.text) as Record<string, unknown>; |
| 126 | }); |
| 127 | |
| 128 | scenario( |
| 129 | "OpenAPI · updating the spec rebuilds tools without re-adding the integration", |
no test coverage detected