mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 05:30:42 +00:00
test: preserve bundled dir fixture helpers
This commit is contained in:
@@ -4,10 +4,14 @@ import { afterEach, describe, expect, it, vi } from "vitest";
|
||||
import type { PluginManifestRegistry } from "../plugins/manifest-registry.js";
|
||||
import { cleanupTrackedTempDirs } from "../plugins/test-helpers/fs-fixtures.js";
|
||||
|
||||
vi.mock("../plugins/bundled-dir.js", () => ({
|
||||
resolveBundledPluginsDir: (env: NodeJS.ProcessEnv = process.env) =>
|
||||
env.OPENCLAW_BUNDLED_PLUGINS_DIR,
|
||||
}));
|
||||
vi.mock("../plugins/bundled-dir.js", async (importOriginal) => {
|
||||
const actual = await importOriginal<typeof import("../plugins/bundled-dir.js")>();
|
||||
return {
|
||||
...actual,
|
||||
resolveBundledPluginsDir: (env: NodeJS.ProcessEnv = process.env) =>
|
||||
env.OPENCLAW_BUNDLED_PLUGINS_DIR,
|
||||
};
|
||||
});
|
||||
|
||||
const tempDirs: string[] = [];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user