summaryrefslogtreecommitdiff
path: root/test/e2e
diff options
context:
space:
mode:
authorPaul Holzinger <paul.holzinger@web.de>2020-09-28 13:34:56 +0200
committerPaul Holzinger <paul.holzinger@web.de>2020-09-28 13:34:56 +0200
commit343a10e25fb12685f18ed3600c567397c01a7cc8 (patch)
tree755a73bf2863a88b5523692f1c920177930620a9 /test/e2e
parent393120c13567ef1b6d42bac357eddf44cfa74d16 (diff)
downloadpodman-343a10e25fb12685f18ed3600c567397c01a7cc8.tar.gz
podman-343a10e25fb12685f18ed3600c567397c01a7cc8.tar.bz2
podman-343a10e25fb12685f18ed3600c567397c01a7cc8.zip
Fix network remove for the podman remote client
The podman remote client ignored the force option due a typo. If an error occured the remote client would panic with an index out of range error. Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
Diffstat (limited to 'test/e2e')
-rw-r--r--test/e2e/network_test.go19
1 files changed, 19 insertions, 0 deletions
diff --git a/test/e2e/network_test.go b/test/e2e/network_test.go
index cdbca3f92..85f67fd51 100644
--- a/test/e2e/network_test.go
+++ b/test/e2e/network_test.go
@@ -294,4 +294,23 @@ var _ = Describe("Podman network", func() {
Expect(session.ExitCode()).To(BeZero())
Expect(session.OutputToString()).To(Not(ContainSubstring(netName)))
})
+
+ It("podman network remove with two networks", func() {
+ netName1 := "net1"
+ session := podmanTest.Podman([]string{"network", "create", netName1})
+ session.WaitWithDefaultTimeout()
+ Expect(session.ExitCode()).To(BeZero())
+
+ netName2 := "net2"
+ session = podmanTest.Podman([]string{"network", "create", netName2})
+ session.WaitWithDefaultTimeout()
+ Expect(session.ExitCode()).To(BeZero())
+
+ session = podmanTest.Podman([]string{"network", "rm", netName1, netName2})
+ session.WaitWithDefaultTimeout()
+ Expect(session.ExitCode()).To(BeZero())
+ lines := session.OutputToStringArray()
+ Expect(lines[0]).To(Equal(netName1))
+ Expect(lines[1]).To(Equal(netName2))
+ })
})