aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMatthew Heon <mheon@redhat.com>2020-07-14 09:44:56 -0400
committerMatthew Heon <mheon@redhat.com>2020-07-14 13:24:12 -0400
commitfbc1167c4d7861013001d0c2460c6e1c1e1ad66d (patch)
tree3cc0c3793d440eca2bfb4910d7c1315259a86ca9 /test
parent1fdfd52eeb513c8d6fad11f53baeef97151775a6 (diff)
downloadpodman-fbc1167c4d7861013001d0c2460c6e1c1e1ad66d.tar.gz
podman-fbc1167c4d7861013001d0c2460c6e1c1e1ad66d.tar.bz2
podman-fbc1167c4d7861013001d0c2460c6e1c1e1ad66d.zip
Fix lint
Signed-off-by: Matthew Heon <mheon@redhat.com>
Diffstat (limited to 'test')
-rw-r--r--test/e2e/pod_inspect_test.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/e2e/pod_inspect_test.go b/test/e2e/pod_inspect_test.go
index 64f943c80..16bf1c4c9 100644
--- a/test/e2e/pod_inspect_test.go
+++ b/test/e2e/pod_inspect_test.go
@@ -1,6 +1,7 @@
package integration
import (
+ "encoding/json"
"os"
"github.com/containers/libpod/v2/libpod/define"
@@ -84,7 +85,7 @@ var _ = Describe("Podman pod inspect", func() {
It("podman pod inspect outputs port bindings", func() {
podName := "testPod"
- create := podmanTest.Podman([]string{"pod", "create", "--name", testPod, "-p", "8080:80"})
+ create := podmanTest.Podman([]string{"pod", "create", "--name", podName, "-p", "8080:80"})
create.WaitWithDefaultTimeout()
Expect(create.ExitCode()).To(Equal(0))
@@ -96,7 +97,7 @@ var _ = Describe("Podman pod inspect", func() {
err := json.Unmarshal(inspectOut.Out.Contents(), inspectJSON)
Expect(err).To(BeNil())
Expect(inspectJSON.InfraConfig).To(Not(BeNil()))
- Expect(len(inspectJSON.PortBindings["80/tcp"])).To(Equal(1))
- Expect(inspectJSON.PortBindings["80/tcp"].HostPort).To(Equal("8080"))
+ Expect(len(inspectJSON.InfraConfig.PortBindings["80/tcp"])).To(Equal(1))
+ Expect(inspectJSON.InfraConfig.PortBindings["80/tcp"][0].HostPort).To(Equal("8080"))
})
})