test(desktop): give the toolset-config-panel @/hermes mock the config-origin helpers
VoiceProviderFields now reads useHermesConfigRecord, which pulls peekConfigReadOrigin/retainConfigReadOrigin from the '@/hermes' barrel. The panel test's hand-rolled '@/hermes' mock predates those exports, so the two TTS-row tests threw "No peekConfigReadOrigin export is defined on the mock" and timed out. Provide inert stubs (no origin, identity retain); the panel tests are not about write routing. Blank-line padding fixed by eslint --fix.
This commit is contained in:
@@ -49,6 +49,9 @@ const saveHermesConfigRecord = vi.fn()
|
||||
const getElevenLabsVoices = vi.fn()
|
||||
|
||||
vi.mock('@/hermes', () => ({
|
||||
// useHermesConfigRecord (via VoiceProviderFields) reads these from the barrel.
|
||||
peekConfigReadOrigin: () => undefined,
|
||||
retainConfigReadOrigin: (next: unknown) => next,
|
||||
getToolsetConfig: (name: string) => getToolsetConfig(name),
|
||||
getToolsetModels: (name: string, provider?: string) => getToolsetModels(name, provider),
|
||||
selectToolsetModel: (name: string, model: string, provider?: string) => selectToolsetModel(name, model, provider),
|
||||
|
||||
Reference in New Issue
Block a user