MCPcopy Index your code
hub / github.com/docker/cli / TestRemoveWithEmptyName

Function TestRemoveWithEmptyName

cli/command/stack/remove_test.go:44–51  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

42}
43
44func TestRemoveWithEmptyName(t *testing.T) {
45 cmd := newRemoveCommand(test.NewFakeCli(&fakeClient{}))
46 cmd.SetArgs([]string{"good", "' '", "alsogood"})
47 cmd.SetOut(io.Discard)
48 cmd.SetErr(io.Discard)
49
50 assert.ErrorContains(t, cmd.Execute(), `invalid stack name: "' '"`)
51}
52
53func TestRemoveStackRemovesEverything(t *testing.T) {
54 apiClient := fakeClientForRemoveStackTest()

Callers

nothing calls this directly

Calls 4

SetArgsMethod · 0.80
newRemoveCommandFunction · 0.70
SetOutMethod · 0.45
SetErrMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…