[manager] Fix test failures and missing type definitions

- Fix ManagerProgressDialogContent test mock to include all required store methods
- Add missing MergedNodePack, RegistryPack type definitions and isMergedNodePack type guard
- Ensure all unit tests (548 passed) and component tests (174 passed) are working
- Fix TypeScript compilation errors related to manager store interfaces
This commit is contained in:
bymyself
2025-06-13 20:00:45 -07:00
parent 39ad01826a
commit 5e4371507f
2 changed files with 30 additions and 2 deletions

View File

@@ -30,11 +30,20 @@ const defaultMockTaskLogs = [
vi.mock('@/stores/comfyManagerStore', () => ({
useComfyManagerStore: vi.fn(() => ({
taskLogs: [...defaultMockTaskLogs]
taskLogs: [...defaultMockTaskLogs],
succeededTasksLogs: [...defaultMockTaskLogs],
failedTasksLogs: [...defaultMockTaskLogs],
managerQueue: { historyCount: 2 },
isLoading: false
})),
useManagerProgressDialogStore: vi.fn(() => ({
isExpanded: true,
collapse: mockCollapse
activeTabIndex: 0,
getActiveTabIndex: vi.fn(() => 0),
setActiveTabIndex: vi.fn(),
toggle: vi.fn(),
collapse: mockCollapse,
expand: vi.fn()
}))
}))