Skip to content

Commit

Permalink
fix: windows paths in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
gmickel committed Jul 20, 2024
1 parent 15fdeaa commit 22993f4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/unit/file-processor.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,9 @@ describe('processFiles', () => {
});

expect(result.length).toBe(3);

Check failure on line 185 in tests/unit/file-processor.test.ts

View workflow job for this annotation

GitHub Actions / test (lts/*, windows-latest)

tests/unit/file-processor.test.ts > processFiles > should use cache for unchanged files

AssertionError: expected 2 to be 3 // Object.is equality - Expected + Received - 3 + 2 ❯ tests/unit/file-processor.test.ts:185:27
const mainJsFile = result.find((file) => file.path === cachedFile.path);
const mainJsFile = result.find(
(file) => path.normalize(file.path) === path.normalize(cachedFile.path),
);
expect(mainJsFile).toEqual(cachedFile);

expect(FileCache.prototype.get).toHaveBeenCalledTimes(3);
Expand Down

0 comments on commit 22993f4

Please sign in to comment.