diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2019-10-31 22:05:17 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-10-31 22:05:17 +0100 |
commit | 2dae2577ccbeef502a8783c892a6c9e346153532 (patch) | |
tree | 34bc708c058597eb0e9c82f4cdbc6e308d6b4497 /test/e2e/logs_test.go | |
parent | 0bfdeae6ddfab22990eaa472317d65e79a222db3 (diff) | |
parent | 11750df51015a675c1145982847e08397c7606ea (diff) | |
download | podman-2dae2577ccbeef502a8783c892a6c9e346153532.tar.gz podman-2dae2577ccbeef502a8783c892a6c9e346153532.tar.bz2 podman-2dae2577ccbeef502a8783c892a6c9e346153532.zip |
Merge pull request #4399 from giuseppe/tail-0
logs: support --tail 0
Diffstat (limited to 'test/e2e/logs_test.go')
-rw-r--r-- | test/e2e/logs_test.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/e2e/logs_test.go b/test/e2e/logs_test.go index f34d85d76..e25364695 100644 --- a/test/e2e/logs_test.go +++ b/test/e2e/logs_test.go @@ -57,6 +57,18 @@ var _ = Describe("Podman logs", func() { Expect(len(results.OutputToStringArray())).To(Equal(2)) }) + It("podman logs tail zero lines", func() { + logc := podmanTest.Podman([]string{"run", "-dt", ALPINE, "sh", "-c", "echo podman; echo podman; echo podman"}) + logc.WaitWithDefaultTimeout() + Expect(logc.ExitCode()).To(Equal(0)) + cid := logc.OutputToString() + + results := podmanTest.Podman([]string{"logs", "--tail", "0", cid}) + results.WaitWithDefaultTimeout() + Expect(results.ExitCode()).To(Equal(0)) + Expect(len(results.OutputToStringArray())).To(Equal(0)) + }) + It("podman logs tail 99 lines", func() { logc := podmanTest.Podman([]string{"run", "-dt", ALPINE, "sh", "-c", "echo podman; echo podman; echo podman"}) logc.WaitWithDefaultTimeout() |