feat: refactor tests and improve mocking for file-service and GitHub polling
- Updated mocking strategy for node:fs and node:fs/promises in file-service tests. - Removed redundant test files and improved test implementations for better clarity. - Enhanced GitHub polling service tests with rate limiter integration.
This commit is contained in:
@@ -17,6 +17,8 @@ vi.mock("lucide-react", () => ({
|
||||
Lightbulb: () => null,
|
||||
ListTree: () => null,
|
||||
Zap: () => null,
|
||||
ChevronDown: () => null,
|
||||
ChevronUp: () => null,
|
||||
}));
|
||||
|
||||
// Mock the api module
|
||||
@@ -28,6 +30,7 @@ vi.mock("../../api", () => ({
|
||||
defaultPresetBySize: {},
|
||||
}),
|
||||
uploadAttachment: vi.fn(),
|
||||
updateGlobalSettings: vi.fn(),
|
||||
}));
|
||||
|
||||
const MOCK_MODELS: ModelInfo[] = [
|
||||
|
||||
Reference in New Issue
Block a user