MCPcopy Create free account
hub / github.com/anomalyco/opencode / expectSelectOption

Function expectSelectOption

packages/opencode/test/cli/acp/helpers.ts:78–82  ·  view source on GitHub ↗
(options: SessionConfigOption[] | null | undefined, id: string)

Source from the content-addressed store, hash-verified

76}
77
78export function expectSelectOption(options: SessionConfigOption[] | null | undefined, id: string) {
79 const option = selectConfigOption(options, id)
80 expect(option).toBeDefined()
81 return option!
82}
83
84export function expectAlternateValue(option: ReturnType<typeof expectSelectOption>) {
85 const value = flattenSelectOptions(option).find((item) => item.value !== option.currentValue)?.value

Callers 1

Calls 1

selectConfigOptionFunction · 0.90

Tested by

no test coverage detected