From fa6cef22c2baf3987b581c673bb416ef0585daf7 Mon Sep 17 00:00:00 2001 From: Matt Heon Date: Mon, 28 Sep 2026 10:28:29 -0400 Subject: [PATCH] Rework podman run checkpoint test Needs to properly handle the error now that we've removed the functionality. Signed-off-by: Matt Heon --- test/e2e/checkpoint_image_test.go | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/test/e2e/checkpoint_image_test.go b/test/e2e/checkpoint_image_test.go index 9fd23ad99d..270ffa6f2b 100644 --- a/test/e2e/checkpoint_image_test.go +++ b/test/e2e/checkpoint_image_test.go @@ -275,7 +275,7 @@ var _ = Describe("Podman checkpoint", func() { Expect(podmanTest.NumberOfContainersRunning()).To(Equal(0)) }) - It("podman run with checkpoint image", func() { + It("podman run with checkpoint image throws an error", func() { // Container image must be lowercase checkpointImage := "alpine-checkpoint-" + strings.ToLower(RandomString(6)) containerName := "alpine-container-" + RandomString(6) @@ -301,19 +301,7 @@ var _ = Describe("Podman checkpoint", func() { // Restore containers from image using `podman run` result = podmanTest.Podman([]string{"run", checkpointImage}) result.WaitWithDefaultTimeout() - Expect(result).Should(ExitCleanly()) - Expect(podmanTest.NumberOfContainersRunning()).To(Equal(1)) - - // Check if the container is running - status := podmanTest.Podman([]string{"inspect", containerName, "--format={{.State.Status}}"}) - status.WaitWithDefaultTimeout() - Expect(status).Should(ExitCleanly()) - Expect(status.OutputToString()).To(Equal("running")) - - // Clean-up - result = podmanTest.Podman([]string{"rm", "-t", "0", "-fa"}) - result.WaitWithDefaultTimeout() - Expect(result).Should(ExitCleanly()) + Expect(result).Should(ExitWithError(125, "is a checkpoint and must be started using `podman container restore` instead")) Expect(podmanTest.NumberOfContainersRunning()).To(Equal(0)) result = podmanTest.Podman([]string{"rmi", checkpointImage})