import { afterEach, beforeAll, beforeEach, vi } from "vitest"; import type { AuthProfileStore } from "../agents/auth-profiles.js"; import type { OpenClawConfig } from "../config/config.js"; import { createEmptyPluginRegistry } from "../plugins/registry.js"; import { setActivePluginRegistry } from "../plugins/runtime.js"; import type { PluginWebSearchProviderEntry } from "../plugins/types.js";
type PrepareSecretsRuntimeSnapshot = typeofimport("./runtime.js").prepareSecretsRuntimeSnapshot;
type WebProviderUnderTest = "brave" | "gemini" | "grok" | "kimi" | "perplexity";
export function resetPluginWebSearchProvidersMock() {
resolvePluginWebSearchProvidersMock.mockReset();
resolvePluginWebSearchProvidersMock.mockReturnValue(buildTestWebSearchProviders());
}
export function getResolvePluginWebSearchProvidersMock() { return resolvePluginWebSearchProvidersMock;
}
export function setupSecretsRuntimeSnapshotTestHooks(): {
prepareSecretsRuntimeSnapshot: PrepareSecretsRuntimeSnapshot;
} {
let clearConfigCache: typeofimport("../config/config.js").clearConfigCache;
let clearRuntimeConfigSnapshot: typeofimport("../config/config.js").clearRuntimeConfigSnapshot;
let clearSecretsRuntimeSnapshot: typeofimport("./runtime.js").clearSecretsRuntimeSnapshot;
let prepareSecretsRuntimeSnapshotImpl: PrepareSecretsRuntimeSnapshot;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.