DockerCLI/cli/command/swarm
Sebastiaan van Stijn b08e34b9f9
swarm: TestSwarmUpdate: remove non-existing "--quiet" flag
The `docker swarm update` copmmand does not have a `--quiet` flag, but this
test was trying to set it.

    docker swarm update --help

    Usage:  docker swarm update [OPTIONS]

    Update the swarm

    Options:
          --autolock                        Change manager autolocking setting (true|false)
          --cert-expiry duration            Validity period for node certificates (ns|us|ms|s|m|h) (default 2160h0m0s)
          --dispatcher-heartbeat duration   Dispatcher heartbeat period (ns|us|ms|s|m|h) (default 5s)
          --external-ca external-ca         Specifications of one or more certificate signing endpoints
          --max-snapshots uint              Number of additional Raft snapshots to retain
          --snapshot-interval uint          Number of log entries between Raft snapshots (default 10000)
          --task-history-limit int          Task history retention limit (default 5)

The test didn't catch this issue, because errors when setting the flag were
not handled, so also adding error-handling;

    === Failed
    === FAIL: cli/command/swarm TestSwarmUpdate (0.00s)
        update_test.go:177: assertion failed: error is not nil: no such flag -quiet

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-10-23 15:21:29 +02:00
..
progress Switch from x/net/context to context 2018-05-11 16:49:43 -07:00
testdata Update code for upstream cobra 2017-10-25 14:49:26 -04:00
ca.go Adopt Cobra completion v2 to support completion by CLI plugins 2022-05-12 12:59:10 +02:00
ca_test.go format code with gofumpt 2022-09-30 11:59:11 +02:00
client_test.go replace uses of deprecated api/types that moved to api/types/system 2023-07-15 01:20:49 +02:00
cmd.go hide swarm-related commands based on the current swarm status and role 2022-05-02 14:57:59 +02:00
init.go cmd: set double quotes as code delimiter 2023-01-06 19:15:33 +01:00
init_test.go cli/command/swarm: remove deprecated io/ioutil and use t.TempDir() 2022-02-25 15:42:11 +01:00
ipnet_slice.go format code with gofumpt 2022-09-30 11:59:11 +02:00
ipnet_slice_test.go cli/command/swarm: fakeClient: remove name for unused arg (revive) 2023-03-30 17:22:09 +02:00
join.go cmd: set double quotes as code delimiter 2023-01-06 19:15:33 +01:00
join_test.go replace uses of deprecated api/types that moved to api/types/system 2023-07-15 01:20:49 +02:00
join_token.go hide swarm-related commands based on the current swarm status and role 2022-05-02 14:57:59 +02:00
join_token_test.go replace uses of deprecated api/types that moved to api/types/system 2023-07-15 01:20:49 +02:00
leave.go Adopt Cobra completion v2 to support completion by CLI plugins 2022-05-12 12:59:10 +02:00
leave_test.go cli/command/swarm: remove deprecated io/ioutil and use t.TempDir() 2022-02-25 15:42:11 +01:00
opts.go cli/command/swarm: use strings.Cut 2022-12-29 15:19:30 +01:00
opts_test.go linting: ST1005: error strings should not be capitalized (stylecheck) 2022-09-03 21:25:42 +02:00
unlock.go Adopt Cobra completion v2 to support completion by CLI plugins 2022-05-12 12:59:10 +02:00
unlock_key.go Adopt Cobra completion v2 to support completion by CLI plugins 2022-05-12 12:59:10 +02:00
unlock_key_test.go cli/command/swarm: remove deprecated io/ioutil and use t.TempDir() 2022-02-25 15:42:11 +01:00
unlock_test.go replace uses of deprecated api/types that moved to api/types/system 2023-07-15 01:20:49 +02:00
update.go Adopt Cobra completion v2 to support completion by CLI plugins 2022-05-12 12:59:10 +02:00
update_test.go swarm: TestSwarmUpdate: remove non-existing "--quiet" flag 2023-10-23 15:21:29 +02:00