diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-12-17 02:25:49 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-17 02:25:49 +0100 |
commit | c9a3f4ec44c4507c0a801635b93d840723826b7a (patch) | |
tree | 3497f656c5bf82b926f5db9f4d80094d1f39a852 /test | |
parent | 52d5f367b144f755dd20b18d88c5f79bc6b0c3fe (diff) | |
parent | e88c21366d33dccb25ef292610b9894aa5087260 (diff) | |
download | podman-c9a3f4ec44c4507c0a801635b93d840723826b7a.tar.gz podman-c9a3f4ec44c4507c0a801635b93d840723826b7a.tar.bz2 podman-c9a3f4ec44c4507c0a801635b93d840723826b7a.zip |
Merge pull request #12634 from baude/bz2024229
Removed .service file for healthchecks
Diffstat (limited to 'test')
-rw-r--r-- | test/e2e/healthcheck_run_test.go | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/e2e/healthcheck_run_test.go b/test/e2e/healthcheck_run_test.go index 6e4dc5bbf..c2084a6fd 100644 --- a/test/e2e/healthcheck_run_test.go +++ b/test/e2e/healthcheck_run_test.go @@ -242,4 +242,20 @@ var _ = Describe("Podman healthcheck run", func() { Expect(ps.OutputToStringArray()).To(HaveLen(2)) Expect(ps.OutputToString()).To(ContainSubstring("hc")) }) + + It("stopping and then starting a container with healthcheck cmd", func() { + session := podmanTest.Podman([]string{"run", "-dt", "--name", "hc", "--health-cmd", "[\"ls\", \"/foo\"]", ALPINE, "top"}) + session.WaitWithDefaultTimeout() + Expect(session).Should(Exit(0)) + + stop := podmanTest.Podman([]string{"stop", "-t0", "hc"}) + stop.WaitWithDefaultTimeout() + Expect(stop).Should(Exit(0)) + + startAgain := podmanTest.Podman([]string{"start", "hc"}) + startAgain.WaitWithDefaultTimeout() + Expect(startAgain).Should(Exit(0)) + Expect(startAgain.OutputToString()).To(Equal("hc")) + Expect(startAgain.ErrorToString()).To(Equal("")) + }) }) |