Make glob.test.ts win compatible. (#4891)
This commit is contained in:
parent
4c144e616d
commit
be898710fe
|
@ -150,11 +150,19 @@ describe('GlobTool', () => {
|
|||
expect(typeof llmContent).toBe('string');
|
||||
|
||||
const filesListed = llmContent
|
||||
.substring(llmContent.indexOf(':') + 1)
|
||||
.trim()
|
||||
.split('\n');
|
||||
expect(filesListed[0]).toContain(path.join(tempRootDir, 'newer.sortme'));
|
||||
expect(filesListed[1]).toContain(path.join(tempRootDir, 'older.sortme'));
|
||||
.split(/\r?\n/)
|
||||
.slice(1)
|
||||
.map((line) => line.trim())
|
||||
.filter(Boolean);
|
||||
|
||||
expect(filesListed).toHaveLength(2);
|
||||
expect(path.resolve(filesListed[0])).toBe(
|
||||
path.resolve(tempRootDir, 'newer.sortme'),
|
||||
);
|
||||
expect(path.resolve(filesListed[1])).toBe(
|
||||
path.resolve(tempRootDir, 'older.sortme'),
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue