summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorValentin Rothberg <rothberg@redhat.com>2020-07-09 15:11:31 +0200
committerValentin Rothberg <rothberg@redhat.com>2020-07-09 15:18:15 +0200
commitd0ebea06437f05dfd42ec50e1eef2da0310b65d9 (patch)
tree4b5d4a88fc6fb8d2059a21dbf4e63988c500f37c
parent09dc77aedfb786505bc526536be18d457fb7c68b (diff)
downloadpodman-d0ebea06437f05dfd42ec50e1eef2da0310b65d9.tar.gz
podman-d0ebea06437f05dfd42ec50e1eef2da0310b65d9.tar.bz2
podman-d0ebea06437f05dfd42ec50e1eef2da0310b65d9.zip
logs: enable e2e tests
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
-rw-r--r--cmd/podman/containers/logs.go2
-rw-r--r--test/e2e/logs_test.go5
2 files changed, 2 insertions, 5 deletions
diff --git a/cmd/podman/containers/logs.go b/cmd/podman/containers/logs.go
index 850cb2e1f..966998877 100644
--- a/cmd/podman/containers/logs.go
+++ b/cmd/podman/containers/logs.go
@@ -32,6 +32,8 @@ var (
Long: logsDescription,
Args: func(cmd *cobra.Command, args []string) error {
switch {
+ case registry.IsRemote() && logsOptions.Latest:
+ return errors.New(cmd.Name() + " does not support 'latest' when run remotely")
case registry.IsRemote() && len(args) > 1:
return errors.New(cmd.Name() + " does not support multiple containers when run remotely")
case logsOptions.Latest && len(args) > 0:
diff --git a/test/e2e/logs_test.go b/test/e2e/logs_test.go
index 1ceab9161..dd69e4ce8 100644
--- a/test/e2e/logs_test.go
+++ b/test/e2e/logs_test.go
@@ -121,7 +121,6 @@ var _ = Describe("Podman logs", func() {
})
It("latest and container name should fail", func() {
- SkipIfRemote() // -l not supported
results := podmanTest.Podman([]string{"logs", "-l", "foobar"})
results.WaitWithDefaultTimeout()
Expect(results).To(ExitWithError())
@@ -159,7 +158,6 @@ var _ = Describe("Podman logs", func() {
})
It("using journald for container with container tag", func() {
- SkipIfRemote()
Skip("need to verify images have correct packages for journald")
logc := podmanTest.Podman([]string{"run", "--log-driver", "journald", "--log-opt=tag={{.ImageName}}", "-d", ALPINE, "sh", "-c", "echo podman; sleep 0.1; echo podman; sleep 0.1; echo podman"})
logc.WaitWithDefaultTimeout()
@@ -178,7 +176,6 @@ var _ = Describe("Podman logs", func() {
It("using journald for container name", func() {
Skip("need to verify images have correct packages for journald")
- SkipIfRemote()
containerName := "inside-journal"
logc := podmanTest.Podman([]string{"run", "--log-driver", "journald", "-d", "--name", containerName, ALPINE, "sh", "-c", "echo podman; sleep 0.1; echo podman; sleep 0.1; echo podman"})
logc.WaitWithDefaultTimeout()
@@ -273,7 +270,6 @@ var _ = Describe("Podman logs", func() {
})
It("streaming output", func() {
- Skip(v2remotefail)
containerName := "logs-f-rm"
logc := podmanTest.Podman([]string{"run", "--rm", "--name", containerName, "-dt", ALPINE, "sh", "-c", "echo podman; sleep 1; echo podman"})
@@ -314,7 +310,6 @@ var _ = Describe("Podman logs", func() {
})
It("follow output stopped container", func() {
- Skip(v2remotefail)
containerName := "logs-f"
logc := podmanTest.Podman([]string{"run", "--name", containerName, "-d", ALPINE, "true"})