({
store,
ideMessenger,
editConfig,
newProfileId,
}: TestConfigUpdateParams)
| 13 | } |
| 14 | |
| 15 | export function triggerConfigUpdate({ |
| 16 | store, |
| 17 | ideMessenger, |
| 18 | editConfig, |
| 19 | newProfileId, |
| 20 | }: TestConfigUpdateParams) { |
| 21 | const state = store.getState(); |
| 22 | ideMessenger.mockMessageToWebview("configUpdate", { |
| 23 | profileId: newProfileId ?? state.profiles.selectedProfileId, |
| 24 | profiles: state.profiles.profiles, |
| 25 | result: { |
| 26 | config: editConfig |
| 27 | ? editConfig(copyOf(state.config.config)) |
| 28 | : state.config.config, |
| 29 | configLoadInterrupted: false, |
| 30 | errors: [], |
| 31 | }, |
| 32 | }); |
| 33 | } |
| 34 | |
| 35 | export function addAndSelectChatModel( |
| 36 | store: EnhancedStore, |
no test coverage detected