We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a02cd20 commit 7299f33Copy full SHA for 7299f33
1 file changed
packages/compiler/src/utils/id.spec.ts
@@ -0,0 +1,15 @@
1
+import { describe, it, expect } from 'vitest';
2
+import { generateFileId } from './id';
3
+
4
+describe('generateFileId', () => {
5
+ it('should generate the same id for both windows and unix relative paths', () => {
6
+ const windowsPath = 'src\\components\\Button.tsx';
7
+ const unixPath = 'src/components/Button.tsx';
8
+ const nonce = 0;
9
10
+ const windowsId = generateFileId(windowsPath, nonce);
11
+ const unixId = generateFileId(unixPath, nonce);
12
13
+ expect(windowsId).toBe(unixId);
14
+ });
15
+});
0 commit comments