MCPcopy Create free account
hub / github.com/github/gh-aw / TestPromptNonInteractiveMultiSelect_OutOfRange

Function TestPromptNonInteractiveMultiSelect_OutOfRange

pkg/cli/interactive_test.go:870–877  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

868}
869
870func TestPromptNonInteractiveMultiSelect_OutOfRange(t *testing.T) {
871 opts := []struct{ label, value string }{{"Option A", "a"}}
872 scanner := newScannerFromString("99")
873 _, err := promptNonInteractiveMultiSelect(scanner, "Pick tools", opts)
874 if err == nil {
875 t.Fatal("expected error for out-of-range index, got nil")
876 }
877}
878
879func TestPromptNonInteractiveMultiSelect_UnknownValue(t *testing.T) {
880 opts := []struct{ label, value string }{{"Option A", "a"}}

Callers

nothing calls this directly

Calls 2

newScannerFromStringFunction · 0.85

Tested by

no test coverage detected