(t *testing.T)
| 84 | } |
| 85 | |
| 86 | func TestStackServicesWithQuietOption(t *testing.T) { |
| 87 | cli := test.NewFakeCli(&fakeClient{ |
| 88 | serviceListFunc: func(options client.ServiceListOptions) (client.ServiceListResult, error) { |
| 89 | return client.ServiceListResult{ |
| 90 | Items: []swarm.Service{*builders.Service(builders.ServiceID("id-foo"))}, |
| 91 | }, nil |
| 92 | }, |
| 93 | }) |
| 94 | cmd := newServicesCommand(cli) |
| 95 | assert.Check(t, cmd.Flags().Set("quiet", "true")) |
| 96 | cmd.SetArgs([]string{"foo"}) |
| 97 | assert.NilError(t, cmd.Execute()) |
| 98 | golden.Assert(t, cli.OutBuffer().String(), "stack-services-with-quiet-option.golden") |
| 99 | } |
| 100 | |
| 101 | func TestStackServicesWithFormat(t *testing.T) { |
| 102 | cli := test.NewFakeCli(&fakeClient{ |
nothing calls this directly
no test coverage detected
searching dependent graphs…