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

Function TestCompleteEngineNamesExactMatch

pkg/cli/completions_test.go:694–702  ·  view source on GitHub ↗

TestCompleteEngineNamesExactMatch tests when toComplete exactly matches an engine name

(t *testing.T)

Source from the content-addressed store, hash-verified

692
693// TestCompleteEngineNamesExactMatch tests when toComplete exactly matches an engine name
694func TestCompleteEngineNamesExactMatch(t *testing.T) {
695 cmd := &cobra.Command{}
696
697 // Test exact match - should still return the matching engine
698 completions, directive := CompleteEngineNames(cmd, nil, "copilot")
699 assert.Equal(t, cobra.ShellCompDirectiveNoFileComp, directive)
700 assert.Len(t, completions, 1, "Should return copilot")
701 assert.Contains(t, completions, "copilot")
702}
703
704// TestCompleteEngineNamesCaseSensitivity tests engine name completion is case-sensitive
705func TestCompleteEngineNamesCaseSensitivity(t *testing.T) {

Callers

nothing calls this directly

Calls 1

CompleteEngineNamesFunction · 0.85

Tested by

no test coverage detected