Description
When running npx vitest run, WorkspacePanel tests trigger an unhandled exception in ConfigHistoryView:
TypeError: Cannot read properties of undefined (reading 'size_bytes')
in ConfigHistoryView.svelte
in WorkspacePanel.svelte
This occurs twice (in two different WorkspacePanel test contexts). The root cause is that the invoke('get_config_history') mock doesn't return the expected data shape, so the component accesses .size_bytes on undefined.
Impact
- All tests still pass (711/711), but vitest reports it as an "Unhandled Error"
- Could mask real failures in the future
Expected Fix
Ensure ConfigHistoryView handles missing/undefined config history entries gracefully (optional chaining or default values), and/or update the WorkspacePanel test mocks to return the expected shape.