mirror of
https://github.com/zadam/trilium.git
synced 2026-01-03 13:14:24 +01:00
fix(server/test): non-platform agnostic test
This commit is contained in:
parent
5bc4bdaeef
commit
37a79aeeab
@ -55,7 +55,7 @@ describe('ChatStorageService', () => {
|
||||
beforeEach(async () => {
|
||||
vi.clearAllMocks();
|
||||
chatStorageService = new ChatStorageService();
|
||||
|
||||
|
||||
// Get mocked modules
|
||||
mockNotes = (await import('../notes.js')).default;
|
||||
mockSql = (await import('../sql.js')).default;
|
||||
@ -177,7 +177,7 @@ describe('ChatStorageService', () => {
|
||||
const result = await chatStorageService.createChat('');
|
||||
|
||||
expect(result.title).toContain('New Chat');
|
||||
expect(result.title).toMatch(/\d{1,2}\/\d{1,2}\/\d{4}/); // Date pattern
|
||||
expect(result.title).toMatch(/\d{4}/);
|
||||
});
|
||||
});
|
||||
|
||||
@ -622,4 +622,4 @@ describe('ChatStorageService', () => {
|
||||
expect(toolExecutions[0].arguments).toEqual({ query: 'existing' });
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user