diff options
Diffstat (limited to 'test/e2e/diff_test.go')
-rw-r--r-- | test/e2e/diff_test.go | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/test/e2e/diff_test.go b/test/e2e/diff_test.go index 71696f5b6..a872a9713 100644 --- a/test/e2e/diff_test.go +++ b/test/e2e/diff_test.go @@ -53,7 +53,7 @@ var _ = Describe("Podman diff", func() { session := podmanTest.Podman([]string{"diff", "--format=json", ALPINE}) session.WaitWithDefaultTimeout() Expect(session).Should(Exit(0)) - Expect(session.IsJSONOutputValid()).To(BeTrue()) + Expect(session.OutputToString()).To(BeValidJSON()) }) It("podman diff container and committed image", func() { @@ -120,13 +120,13 @@ RUN echo test session := podmanTest.Podman([]string{"image", "diff", image}) session.WaitWithDefaultTimeout() Expect(session).Should(Exit(0)) - Expect(len(session.OutputToStringArray())).To(BeNumerically("==", 1)) + Expect(session.OutputToStringArray()).To(HaveLen(1)) Expect(session.OutputToString()).To(Equal("A " + file3)) session = podmanTest.Podman([]string{"image", "diff", image, baseImage}) session.WaitWithDefaultTimeout() Expect(session).Should(Exit(0)) - Expect(len(session.OutputToStringArray())).To(BeNumerically("==", 4)) + Expect(session.OutputToStringArray()).To(HaveLen(4)) Expect(session.OutputToString()).To(ContainSubstring("A " + file1)) Expect(session.OutputToString()).To(ContainSubstring("A " + file2)) Expect(session.OutputToString()).To(ContainSubstring("A " + file3)) @@ -149,7 +149,7 @@ RUN echo test session := podmanTest.Podman([]string{"image", "diff", ALPINE, ALPINE}) session.WaitWithDefaultTimeout() Expect(session).Should(Exit(0)) - Expect(len(session.OutputToStringArray())).To(BeNumerically("==", 0)) + Expect(session.OutputToStringArray()).To(BeEmpty()) }) It("podman diff container and image with same name", func() { @@ -172,20 +172,20 @@ RUN touch %s`, ALPINE, imagefile) session = podmanTest.Podman([]string{"diff", name}) session.WaitWithDefaultTimeout() Expect(session).Should(Exit(0)) - Expect(len(session.OutputToStringArray())).To(BeNumerically("==", 2)) + Expect(session.OutputToStringArray()).To(HaveLen(2)) Expect(session.OutputToString()).To(ContainSubstring(imagefile)) session = podmanTest.Podman([]string{"image", "diff", name}) session.WaitWithDefaultTimeout() Expect(session).Should(Exit(0)) - Expect(len(session.OutputToStringArray())).To(BeNumerically("==", 2)) + Expect(session.OutputToStringArray()).To(HaveLen(2)) Expect(session.OutputToString()).To(ContainSubstring(imagefile)) // container diff has to show the container session = podmanTest.Podman([]string{"container", "diff", name}) session.WaitWithDefaultTimeout() Expect(session).Should(Exit(0)) - Expect(len(session.OutputToStringArray())).To(BeNumerically("==", 2)) + Expect(session.OutputToStringArray()).To(HaveLen(2)) Expect(session.OutputToString()).To(ContainSubstring(confile)) }) |