import { AuthConnectionTokenResult, ConnectionName } from "@tailor-platform/sdk"; //#region src/vitest/mocks/authconnection.d.ts interface AuthConnectionCall { connectionName: ConnectionName; } /** Initial fixtures and fallback behavior for an AuthConnection mock. */ export interface MockAuthconnectionOptions { /** Tokens available when the mock is acquired. */ tokens?: Partial>; /** Return a placeholder token or throw when a connection has no configured token. */ onUnhandled?: "fallback" | "error"; } /** * Acquire a disposable mock for `tailor.authconnection`. Restored on dispose. * @param options - Initial token fixtures and fallback behavior * @returns Disposable AuthConnection mock control object * @example * ```typescript * import { mockAuthconnection } from "@tailor-platform/sdk/vitest"; * * test("returns configured token", async () => { * using ac = mockAuthconnection({ tokens: { google: { access_token: "ya29.xxx" } } }); * ac.setToken("google", { access_token: "replacement" }); * // … * }); * ``` */ export declare function mockAuthconnection(options?: MockAuthconnectionOptions): { /** The `getConnectionToken` `vi.fn`. */ getConnectionToken: import("vitest").Mock<(connectionName: ConnectionName) => Promise>; setTokens(value: Partial>): void; setToken(connectionName: ConnectionName, token: AuthConnectionTokenResult): void; readonly calls: AuthConnectionCall[]; clear(): void; reset(): void; } & Disposable; //#endregion