From af0f7e1bc7a51925cecdea0882929bb1c9c0e6b3 Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Fri, 17 Apr 2026 21:56:25 +0100 Subject: [PATCH] test: type runtime auth overlay mock --- src/agents/auth-profiles.store-cache.test.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/agents/auth-profiles.store-cache.test.ts b/src/agents/auth-profiles.store-cache.test.ts index f619b7d9bb3..ca801543780 100644 --- a/src/agents/auth-profiles.store-cache.test.ts +++ b/src/agents/auth-profiles.store-cache.test.ts @@ -4,7 +4,11 @@ import path from "node:path"; import { afterEach, beforeEach, describe, expect, it, vi } from "vitest"; import { AUTH_STORE_VERSION } from "./auth-profiles/constants.js"; -const resolveExternalAuthProfilesWithPluginsMock = vi.fn(() => []); +type ExternalAuthProfiles = ReturnType< + typeof import("../plugins/provider-runtime.js").resolveExternalAuthProfilesWithPlugins +>; + +const resolveExternalAuthProfilesWithPluginsMock = vi.fn<() => ExternalAuthProfiles>(() => []); vi.mock("../plugins/provider-runtime.js", () => ({ resolveExternalAuthProfilesWithPlugins: resolveExternalAuthProfilesWithPluginsMock,