fix(checkpoints): correct Windows Thumbs cache pattern (Thumbs.db) and add unit test (#7228)

This commit is contained in:
hannesrudolph 2025-08-19 17:28:54 -06:00
parent 8ca0c46159
commit 72809666ca
2 changed files with 11 additions and 1 deletions

View file

@ -159,6 +159,16 @@ readme.md text
expect(excludePatterns).toContain("*.shp") // geospatial
expect(excludePatterns).toContain("*.log") // log
})
it("should include Windows Thumbs.db cache pattern", async () => {
// Mock .gitattributes file doesn't exist
vi.mocked(fileExistsAtPath).mockResolvedValue(false)
// Get exclude patterns
const excludePatterns = await getExcludePatterns(testWorkspacePath)
// Verify Windows cache file pattern is included
expect(excludePatterns).toContain("Thumbs.db")
})
})
describe("getLargeFileAutoExcludePatterns with LFS pre-filtering", () => {

View file

@ -150,7 +150,7 @@ const getCacheFilePatterns = () => [
"*.swp",
"*.temp",
"*.tmp",
"*.Thumbs.db",
"Thumbs.db",
]
const getConfigFilePatterns = () => ["*.env*", "*.local", "*.development", "*.production"]