fix: honor test planner cache paths by target platform

This commit is contained in:
Peter Steinberger
2026-03-27 07:53:57 +00:00
parent 1b77e6fd72
commit a30dae3c71
2 changed files with 15 additions and 1 deletions

View File

@@ -421,6 +421,19 @@ describe("resolveVitestFsModuleCachePath", () => {
).toBe("/repo/node_modules/.experimental-vitest-cache/unit-fast-1");
});
it("honors the requested Windows platform when building the cache path", () => {
expect(
resolveVitestFsModuleCachePath({
cwd: "/repo",
env: {
OPENCLAW_VITEST_FS_MODULE_CACHE: "1",
},
platform: "win32",
unitId: "unit-fast-1",
}),
).toBe("\\repo\\node_modules\\.experimental-vitest-cache\\unit-fast-1");
});
it("respects an explicit cache path override", () => {
expect(
resolveVitestFsModuleCachePath({