From 720791ae6b4f74792dc028a74d2bab2777552887 Mon Sep 17 00:00:00 2001 From: mbelinky <132747814+mbelinky@users.noreply.github.com> Date: Wed, 18 Feb 2026 14:35:53 +0100 Subject: [PATCH] test(types): annotate cron gateway mock openclaw#20054 thanks @mbelinky --- src/agents/tools/cron-tool.test-helpers.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/agents/tools/cron-tool.test-helpers.ts b/src/agents/tools/cron-tool.test-helpers.ts index 9125c8a86dc..9045636864b 100644 --- a/src/agents/tools/cron-tool.test-helpers.ts +++ b/src/agents/tools/cron-tool.test-helpers.ts @@ -1,6 +1,11 @@ import { vi } from "vitest"; -export const callGatewayMock = vi.fn(); +type GatewayMockFn = ((opts: unknown) => unknown) & { + mockReset: () => void; + mockResolvedValue: (value: unknown) => void; +}; + +export const callGatewayMock = vi.fn() as GatewayMockFn; vi.mock("../../gateway/call.js", () => ({ callGateway: (opts: unknown) => callGatewayMock(opts),