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

@@ -133,10 +133,9 @@ describe("QmdMemoryManager", () => {
tmpRoot = path.join(fixtureRoot, `case-${fixtureCount++}`);
workspaceDir = path.join(tmpRoot, "workspace");
stateDir = path.join(tmpRoot, "state");
await Promise.all([
fs.mkdir(workspaceDir, { recursive: true }),
fs.mkdir(stateDir, { recursive: true }),
]);
// Only workspace must exist for configured collection paths; state paths are
// created lazily by manager code when needed.
await fs.mkdir(workspaceDir, { recursive: true });
process.env.OPENCLAW_STATE_DIR = stateDir;
cfg = {
agents: {