From 12787963b04f91a7fec9aa0d6915666e43aeb269 Mon Sep 17 00:00:00 2001 From: Ed Santiago Date: Tue, 30 Nov 2021 09:15:44 -0700 Subject: e2e tests: more cleanup of BeTrue()s Write a BeValidJSON() matcher, and replace IsJSONOutputValid(): sed -i -e 's/Expect(\(.*\)\.IsJSONOutputValid()).To(BeTrue())/Expect(\1.OutputToString())\.To(BeValidJSON())/' test/e2e/*_test.go (Plus a few manual tweaks) Signed-off-by: Ed Santiago --- test/e2e/diff_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'test/e2e/diff_test.go') diff --git a/test/e2e/diff_test.go b/test/e2e/diff_test.go index 71696f5b6..80647c6f5 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() { -- cgit v1.2.3-54-g00ecf