summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2020-02-20 17:56:08 -0500
committerGitHub <noreply@github.com>2020-02-20 17:56:08 -0500
commita8896d5b6755be23f13f5c4cc0deb60e11155039 (patch)
tree0820228272d0290e52a4358e0868b69274736d69
parenta7a52fdf2be9ecc1176339bdf9c16474aef678d8 (diff)
parentbb31d35d998ab13ca1bcc245132f5de490c9752b (diff)
downloadpodman-a8896d5b6755be23f13f5c4cc0deb60e11155039.tar.gz
podman-a8896d5b6755be23f13f5c4cc0deb60e11155039.tar.bz2
podman-a8896d5b6755be23f13f5c4cc0deb60e11155039.zip
Merge pull request #5284 from edsantiago/flaky_fedora_registry
search test on fedora registry: retry 5 times
-rw-r--r--test/e2e/search_test.go13
1 files changed, 11 insertions, 2 deletions
diff --git a/test/e2e/search_test.go b/test/e2e/search_test.go
index d88231510..a697831ab 100644
--- a/test/e2e/search_test.go
+++ b/test/e2e/search_test.go
@@ -9,6 +9,7 @@ import (
"os"
"strconv"
"text/template"
+ "time"
. "github.com/containers/libpod/test/utils"
. "github.com/onsi/ginkgo"
@@ -165,8 +166,16 @@ registries = ['{{.Host}}:{{.Port}}']`
})
It("podman search v2 registry with empty query", func() {
- search := podmanTest.Podman([]string{"search", "registry.fedoraproject.org/"})
- search.WaitWithDefaultTimeout()
+ var search *PodmanSessionIntegration
+ for i := 0; i < 5; i++ {
+ search = podmanTest.Podman([]string{"search", "registry.fedoraproject.org/"})
+ search.WaitWithDefaultTimeout()
+ if search.ExitCode() == 0 {
+ break
+ }
+ fmt.Println("Search failed; sleeping & retrying...")
+ time.Sleep(2 * time.Second)
+ }
Expect(search.ExitCode()).To(Equal(0))
Expect(len(search.OutputToStringArray())).To(BeNumerically(">=", 1))
})