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

Function TestNewExperimentsCommand

pkg/cli/experiments_command_test.go:299–313  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

297}
298
299func TestNewExperimentsCommand(t *testing.T) {
300 cmd := NewExperimentsCommand()
301 require.NotNil(t, cmd, "command should be created")
302 assert.Equal(t, "experiments", cmd.Name(), "command name should be experiments")
303 assert.True(t, cmd.Hidden, "experiments command should be hidden")
304
305 subCmds := cmd.Commands()
306 subNames := make([]string, 0, len(subCmds))
307 for _, sub := range subCmds {
308 subNames = append(subNames, sub.Name())
309 }
310
311 assert.Contains(t, subNames, "list", "should have list subcommand")
312 assert.Contains(t, subNames, "analyze", "should have analyze subcommand")
313}
314
315func TestExperimentsListSubcommandFlags(t *testing.T) {
316 cmd := NewExperimentsListSubcommand()

Callers

nothing calls this directly

Calls 1

NewExperimentsCommandFunction · 0.85

Tested by

no test coverage detected