summaryrefslogtreecommitdiff
path: root/test/e2e/checkpoint_test.go
diff options
context:
space:
mode:
authorMatthew Heon <mheon@redhat.com>2021-09-07 14:16:01 -0400
committerMatthew Heon <mheon@redhat.com>2021-09-07 14:16:01 -0400
commitbfcd83ecd680fccd2efeadf695a9cd2c603a997f (patch)
treeb0fe8aa8c509228c00d818cff4c13b20f2b83223 /test/e2e/checkpoint_test.go
parent536f23c0b78dd8feafee4e40b743988dbb03bfa2 (diff)
downloadpodman-bfcd83ecd680fccd2efeadf695a9cd2c603a997f.tar.gz
podman-bfcd83ecd680fccd2efeadf695a9cd2c603a997f.tar.bz2
podman-bfcd83ecd680fccd2efeadf695a9cd2c603a997f.zip
Add Checkpointed bool to Inspect
When inspecting a container, we now report whether the container was stopped by a `podman checkpoint` operation via a new bool in the State portion of inspected, `Checkpointed`. Signed-off-by: Matthew Heon <mheon@redhat.com>
Diffstat (limited to 'test/e2e/checkpoint_test.go')
-rw-r--r--test/e2e/checkpoint_test.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/e2e/checkpoint_test.go b/test/e2e/checkpoint_test.go
index 1c9a8dc6f..403d739f0 100644
--- a/test/e2e/checkpoint_test.go
+++ b/test/e2e/checkpoint_test.go
@@ -93,6 +93,12 @@ var _ = Describe("Podman checkpoint", func() {
Expect(podmanTest.NumberOfContainersRunning()).To(Equal(0))
Expect(podmanTest.GetContainerStatus()).To(ContainSubstring("Exited"))
+ inspect := podmanTest.Podman([]string{"inspect", cid})
+ inspect.WaitWithDefaultTimeout()
+ Expect(inspect).Should(Exit(0))
+ inspectOut := inspect.InspectContainerToJSON()
+ Expect(inspectOut[0].State.Checkpointed).To(BeTrue())
+
result = podmanTest.Podman([]string{"container", "restore", cid})
result.WaitWithDefaultTimeout()