test(perf): trim repeated setup in cron memory and config suites

This commit is contained in:
Peter Steinberger
2026-03-02 19:16:28 +00:00
parent 6add2bcc15
commit 83ec545bed
4 changed files with 56 additions and 59 deletions

View File

@@ -41,10 +41,7 @@ describe("config plugin validation", () => {
OPENCLAW_PLUGIN_MANIFEST_CACHE_MS: process.env.OPENCLAW_PLUGIN_MANIFEST_CACHE_MS,
};
const validateInSuite = (raw: unknown) => {
process.env.OPENCLAW_STATE_DIR = path.join(suiteHome, ".openclaw");
return validateConfigObjectWithPlugins(raw);
};
const validateInSuite = (raw: unknown) => validateConfigObjectWithPlugins(raw);
beforeAll(async () => {
fixtureRoot = await fs.mkdtemp(path.join(os.tmpdir(), "openclaw-config-plugin-validation-"));
@@ -70,6 +67,7 @@ describe("config plugin validation", () => {
channels: ["bluebubbles"],
schema: { type: "object" },
});
process.env.OPENCLAW_STATE_DIR = path.join(suiteHome, ".openclaw");
process.env.OPENCLAW_PLUGIN_MANIFEST_CACHE_MS = "10000";
clearPluginManifestRegistryCache();
});