Add retries to auth test checks
This commit is contained in:
parent
5dd1b1319c
commit
564f2a9fe4
1 changed files with 7 additions and 0 deletions
|
@ -20,6 +20,7 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"net/http"
|
"net/http"
|
||||||
"os/exec"
|
"os/exec"
|
||||||
|
"time"
|
||||||
|
|
||||||
. "github.com/onsi/ginkgo"
|
. "github.com/onsi/ginkgo"
|
||||||
. "github.com/onsi/gomega"
|
. "github.com/onsi/gomega"
|
||||||
|
@ -58,6 +59,7 @@ var _ = framework.IngressNginxDescribe("Annotations - Auth", func() {
|
||||||
|
|
||||||
resp, body, errs := gorequest.New().
|
resp, body, errs := gorequest.New().
|
||||||
Get(f.IngressController.HTTPURL).
|
Get(f.IngressController.HTTPURL).
|
||||||
|
Retry(10, 1*time.Second, http.StatusNotFound).
|
||||||
Set("Host", host).
|
Set("Host", host).
|
||||||
End()
|
End()
|
||||||
|
|
||||||
|
@ -90,6 +92,7 @@ var _ = framework.IngressNginxDescribe("Annotations - Auth", func() {
|
||||||
|
|
||||||
resp, body, errs := gorequest.New().
|
resp, body, errs := gorequest.New().
|
||||||
Get(f.IngressController.HTTPURL).
|
Get(f.IngressController.HTTPURL).
|
||||||
|
Retry(10, 1*time.Second, http.StatusNotFound).
|
||||||
Set("Host", host).
|
Set("Host", host).
|
||||||
End()
|
End()
|
||||||
|
|
||||||
|
@ -127,6 +130,7 @@ var _ = framework.IngressNginxDescribe("Annotations - Auth", func() {
|
||||||
|
|
||||||
resp, body, errs := gorequest.New().
|
resp, body, errs := gorequest.New().
|
||||||
Get(f.IngressController.HTTPURL).
|
Get(f.IngressController.HTTPURL).
|
||||||
|
Retry(10, 1*time.Second, http.StatusNotFound).
|
||||||
Set("Host", host).
|
Set("Host", host).
|
||||||
End()
|
End()
|
||||||
|
|
||||||
|
@ -164,6 +168,7 @@ var _ = framework.IngressNginxDescribe("Annotations - Auth", func() {
|
||||||
|
|
||||||
resp, body, errs := gorequest.New().
|
resp, body, errs := gorequest.New().
|
||||||
Get(f.IngressController.HTTPURL).
|
Get(f.IngressController.HTTPURL).
|
||||||
|
Retry(10, 1*time.Second, http.StatusNotFound).
|
||||||
Set("Host", host).
|
Set("Host", host).
|
||||||
SetBasicAuth("user", "pass").
|
SetBasicAuth("user", "pass").
|
||||||
End()
|
End()
|
||||||
|
@ -202,6 +207,7 @@ var _ = framework.IngressNginxDescribe("Annotations - Auth", func() {
|
||||||
|
|
||||||
resp, _, errs := gorequest.New().
|
resp, _, errs := gorequest.New().
|
||||||
Get(f.IngressController.HTTPURL).
|
Get(f.IngressController.HTTPURL).
|
||||||
|
Retry(10, 1*time.Second, http.StatusNotFound).
|
||||||
Set("Host", host).
|
Set("Host", host).
|
||||||
SetBasicAuth("foo", "bar").
|
SetBasicAuth("foo", "bar").
|
||||||
End()
|
End()
|
||||||
|
@ -251,6 +257,7 @@ var _ = framework.IngressNginxDescribe("Annotations - Auth", func() {
|
||||||
|
|
||||||
resp, _, errs := gorequest.New().
|
resp, _, errs := gorequest.New().
|
||||||
Get(f.IngressController.HTTPURL).
|
Get(f.IngressController.HTTPURL).
|
||||||
|
Retry(10, 1*time.Second, http.StatusNotFound).
|
||||||
Set("Host", host).
|
Set("Host", host).
|
||||||
SetBasicAuth("foo", "bar").
|
SetBasicAuth("foo", "bar").
|
||||||
End()
|
End()
|
||||||
|
|
Loading…
Reference in a new issue