MCPcopy Create free account
hub / github.com/Driver-C/tryssh / TestNewAliasCommand_Subcommands

Function TestNewAliasCommand_Subcommands

cmd/alias/alias_test.go:92–106  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

90}
91
92func TestNewAliasCommand_Subcommands(t *testing.T) {
93 cmd := NewAliasCommand()
94
95 expectedSubcommands := []string{"list", "set", "unset"}
96 for _, name := range expectedSubcommands {
97 found := false
98 for _, sub := range cmd.Commands() {
99 if sub.Name() == name {
100 found = true
101 break
102 }
103 }
104 assert.True(t, found, "expected subcommand %q to be registered", name)
105 }
106}
107
108func TestNewAliasCommand_SubcommandCount(t *testing.T) {
109 cmd := NewAliasCommand()

Callers

nothing calls this directly

Calls 1

NewAliasCommandFunction · 0.85

Tested by

no test coverage detected