diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-02-04 16:34:45 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-04 16:34:45 -0500 |
commit | b1bd126cdab1c654570a49b13385a57b5d41f8fd (patch) | |
tree | 9eee72389842780f8133f28982ce0085c233fd30 /test/e2e | |
parent | e6e3520498500f6f81b1aa0a5b538c8069255376 (diff) | |
parent | 5c6ab3075e8fbf8fea7fbb5249189a0216400c41 (diff) | |
download | podman-b1bd126cdab1c654570a49b13385a57b5d41f8fd.tar.gz podman-b1bd126cdab1c654570a49b13385a57b5d41f8fd.tar.bz2 podman-b1bd126cdab1c654570a49b13385a57b5d41f8fd.zip |
Merge pull request #9235 from Luap99/fix-9234
Fix podman network disconnect wrong NetworkStatus number
Diffstat (limited to 'test/e2e')
-rw-r--r-- | test/e2e/network_connect_disconnect_test.go | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/test/e2e/network_connect_disconnect_test.go b/test/e2e/network_connect_disconnect_test.go index dd94bd7ca..cc23b10c1 100644 --- a/test/e2e/network_connect_disconnect_test.go +++ b/test/e2e/network_connect_disconnect_test.go @@ -74,6 +74,11 @@ var _ = Describe("Podman network connect and disconnect", func() { dis.WaitWithDefaultTimeout() Expect(dis.ExitCode()).To(BeZero()) + inspect := podmanTest.Podman([]string{"container", "inspect", "test", "--format", "{{len .NetworkSettings.Networks}}"}) + inspect.WaitWithDefaultTimeout() + Expect(inspect.ExitCode()).To(BeZero()) + Expect(inspect.OutputToString()).To(Equal("0")) + exec = podmanTest.Podman([]string{"exec", "-it", "test", "ip", "addr", "show", "eth0"}) exec.WaitWithDefaultTimeout() Expect(exec.ExitCode()).ToNot(BeZero()) @@ -146,6 +151,11 @@ var _ = Describe("Podman network connect and disconnect", func() { connect.WaitWithDefaultTimeout() Expect(connect.ExitCode()).To(BeZero()) + inspect := podmanTest.Podman([]string{"container", "inspect", "test", "--format", "{{len .NetworkSettings.Networks}}"}) + inspect.WaitWithDefaultTimeout() + Expect(inspect.ExitCode()).To(BeZero()) + Expect(inspect.OutputToString()).To(Equal("2")) + exec = podmanTest.Podman([]string{"exec", "-it", "test", "ip", "addr", "show", "eth1"}) exec.WaitWithDefaultTimeout() Expect(exec.ExitCode()).To(BeZero()) @@ -167,6 +177,11 @@ var _ = Describe("Podman network connect and disconnect", func() { dis.WaitWithDefaultTimeout() Expect(dis.ExitCode()).To(BeZero()) + inspect := podmanTest.Podman([]string{"container", "inspect", "test", "--format", "{{len .NetworkSettings.Networks}}"}) + inspect.WaitWithDefaultTimeout() + Expect(inspect.ExitCode()).To(BeZero()) + Expect(inspect.OutputToString()).To(Equal("2")) + start := podmanTest.Podman([]string{"start", "test"}) start.WaitWithDefaultTimeout() Expect(start.ExitCode()).To(BeZero()) @@ -202,6 +217,11 @@ var _ = Describe("Podman network connect and disconnect", func() { dis.WaitWithDefaultTimeout() Expect(dis.ExitCode()).To(BeZero()) + inspect := podmanTest.Podman([]string{"container", "inspect", "test", "--format", "{{len .NetworkSettings.Networks}}"}) + inspect.WaitWithDefaultTimeout() + Expect(inspect.ExitCode()).To(BeZero()) + Expect(inspect.OutputToString()).To(Equal("1")) + start := podmanTest.Podman([]string{"start", "test"}) start.WaitWithDefaultTimeout() Expect(start.ExitCode()).To(BeZero()) |