MCPcopy
hub / github.com/cli/cli / TestAliasAreSet

Function TestAliasAreSet

pkg/cmd/agent-task/agent_task_test.go:140–149  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

138}
139
140func TestAliasAreSet(t *testing.T) {
141 f := &cmdutil.Factory{}
142 ios, _, _, _ := iostreams.Test()
143 f.IOStreams = ios
144 f.Config = func() (gh.Config, error) { return setupMockOAuthConfig(t, "oauth_token"), nil }
145
146 cmd := NewCmdAgentTask(f)
147
148 require.ElementsMatch(t, []string{"agent-tasks", "agent", "agents"}, cmd.Aliases)
149}

Callers

nothing calls this directly

Calls 3

TestFunction · 0.92
setupMockOAuthConfigFunction · 0.85
NewCmdAgentTaskFunction · 0.85

Tested by

no test coverage detected