mirror of
https://github.com/containers/podman.git
synced 2025-08-26 03:01:31 +08:00
system: Adds support for removing all named destination via --all
Adds support of dropping all named destination from system connections via `--all`. Closes: https://github.com/containers/podman/issues/12018 Signed-off-by: Aditya Rajan <arajan@redhat.com>
This commit is contained in:
@ -181,6 +181,31 @@ var _ = Describe("podman system connection", func() {
|
||||
}
|
||||
})
|
||||
|
||||
It("remove --all", func() {
|
||||
cmd := []string{"system", "connection", "add",
|
||||
"--default",
|
||||
"--identity", "~/.ssh/id_rsa",
|
||||
"QA",
|
||||
"ssh://root@server.fubar.com:2222/run/podman/podman.sock",
|
||||
}
|
||||
session := podmanTest.Podman(cmd)
|
||||
session.WaitWithDefaultTimeout()
|
||||
Expect(session).Should(Exit(0))
|
||||
|
||||
cmd = []string{"system", "connection", "remove", "--all"}
|
||||
session = podmanTest.Podman(cmd)
|
||||
session.WaitWithDefaultTimeout()
|
||||
Expect(session).Should(Exit(0))
|
||||
Expect(session.Out).Should(Say(""))
|
||||
|
||||
cmd = []string{"system", "connection", "list"}
|
||||
session = podmanTest.Podman(cmd)
|
||||
session.WaitWithDefaultTimeout()
|
||||
Expect(session).Should(Exit(0))
|
||||
Expect(session.Out).Should(Say(""))
|
||||
Expect(session.Err).Should(Say(""))
|
||||
})
|
||||
|
||||
It("default", func() {
|
||||
for _, name := range []string{"devl", "qe"} {
|
||||
cmd := []string{"system", "connection", "add",
|
||||
|
Reference in New Issue
Block a user