mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-13 13:30:45 +00:00
test: isolate ollama discovery catalog cache
This commit is contained in:
@@ -2,6 +2,7 @@ import { mkdtempSync } from "node:fs";
|
||||
import { tmpdir } from "node:os";
|
||||
import { join } from "node:path";
|
||||
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-types";
|
||||
import { clearLiveCatalogCacheForTests } from "openclaw/plugin-sdk/provider-catalog-shared";
|
||||
import type { ModelDefinitionConfig } from "openclaw/plugin-sdk/provider-onboard";
|
||||
import { withFetchPreconnect } from "openclaw/plugin-sdk/test-env";
|
||||
import { afterEach, describe, expect, it, vi } from "vitest";
|
||||
@@ -10,6 +11,7 @@ import { ollamaProviderDiscovery } from "./provider-discovery.js";
|
||||
const OLLAMA_LOCAL_AUTH_MARKER = "ollama-local";
|
||||
|
||||
afterEach(() => {
|
||||
clearLiveCatalogCacheForTests();
|
||||
vi.unstubAllEnvs();
|
||||
vi.unstubAllGlobals();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user