diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-12-03 14:50:47 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-03 14:50:47 +0100 |
commit | f0f148c494711f679e75cff5542af75715978dbb (patch) | |
tree | 8d0d7320dc3c427350d1aa945f5cf9ada0748ed5 /test/e2e | |
parent | 0c6f1c4fb13e22ca8e97dd93fba9160d7ef573a1 (diff) | |
parent | c9ad1da51c6b1aa7eb531a2f9951aa853bdea109 (diff) | |
download | podman-f0f148c494711f679e75cff5542af75715978dbb.tar.gz podman-f0f148c494711f679e75cff5542af75715978dbb.tar.bz2 podman-f0f148c494711f679e75cff5542af75715978dbb.zip |
Merge pull request #12484 from machacekondra/restartSec
Add restart-sec option to systemd generate command
Diffstat (limited to 'test/e2e')
-rw-r--r-- | test/e2e/generate_systemd_test.go | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/e2e/generate_systemd_test.go b/test/e2e/generate_systemd_test.go index 1cffdc62e..fd9ae5037 100644 --- a/test/e2e/generate_systemd_test.go +++ b/test/e2e/generate_systemd_test.go @@ -282,6 +282,19 @@ var _ = Describe("Podman generate systemd", func() { Expect(session.OutputToString()).To(ContainSubstring(" pod create ")) }) + It("podman generate systemd --restart-sec 15 --name foo", func() { + n := podmanTest.Podman([]string{"pod", "create", "--name", "foo"}) + n.WaitWithDefaultTimeout() + Expect(n).Should(Exit(0)) + + session := podmanTest.Podman([]string{"generate", "systemd", "--restart-sec", "15", "--name", "foo"}) + session.WaitWithDefaultTimeout() + Expect(session).Should(Exit(0)) + + // Grepping the output (in addition to unit tests) + Expect(session.OutputToString()).To(ContainSubstring("RestartSec=15")) + }) + It("podman generate systemd --new=false pod", func() { n := podmanTest.Podman([]string{"pod", "create", "--name", "foo"}) n.WaitWithDefaultTimeout() |