test(skills): remove scanner cache reset seam (#126199)

This commit is contained in:
Peter Steinberger
2026-08-18 22:35:54 -07:00
committed by GitHub
parent 3550b174e9
commit 95ac5b27fa
2 changed files with 2 additions and 18 deletions
+2 -13
View File
@@ -3,14 +3,8 @@ import fsSync from "node:fs";
import fs from "node:fs/promises";
import os from "node:os";
import path from "node:path";
import { afterAll, afterEach, describe, expect, it, vi } from "vitest";
import {
clearSkillScanCacheForTest,
isScannable,
scanDirectoryWithSummary,
scanSkillContent,
scanSource,
} from "./scanner.js";
import { afterAll, describe, expect, it, vi } from "vitest";
import { isScannable, scanDirectoryWithSummary, scanSkillContent, scanSource } from "./scanner.js";
import type { SkillScanOptions } from "./scanner.js";
// ---------------------------------------------------------------------------
@@ -140,10 +134,6 @@ type SummaryCase = {
};
};
afterEach(() => {
clearSkillScanCacheForTest();
});
// ---------------------------------------------------------------------------
// scanSource
// ---------------------------------------------------------------------------
@@ -815,7 +805,6 @@ describe("scanDirectoryWithSummary", () => {
testCase.expected.expectedPresent,
);
}
clearSkillScanCacheForTest();
});
}
});
-5
View File
@@ -124,11 +124,6 @@ function setCachedDirEntries(dirPath: string, entry: DirEntryCacheEntry): void {
DIR_ENTRY_CACHE.set(dirPath, entry);
}
export function clearSkillScanCacheForTest(): void {
FILE_SCAN_CACHE.clear();
DIR_ENTRY_CACHE.clear();
}
// ---------------------------------------------------------------------------
// Rule definitions
// ---------------------------------------------------------------------------