@@ -17,6 +17,8 @@ import (
17
17
exutil "github.com/openshift/origin/test/extended/util"
18
18
)
19
19
20
+ const changeTimeoutSeconds = 3 * 60
21
+
20
22
var _ = g .Describe ("[networking][router] openshift routers" , func () {
21
23
defer g .GinkgoRecover ()
22
24
var (
@@ -42,7 +44,7 @@ var _ = g.Describe("[networking][router] openshift routers", func() {
42
44
g .By (fmt .Sprintf ("creating a scoped router from a config file %q" , configPath ))
43
45
44
46
var routerIP string
45
- err := wait .Poll (time .Second , 2 * time .Minute , func () (bool , error ) {
47
+ err := wait .Poll (time .Second , changeTimeoutSeconds * time .Second , func () (bool , error ) {
46
48
pod , err := oc .KubeFramework ().ClientSet .Core ().Pods (oc .KubeFramework ().Namespace .Name ).Get ("scoped-router" )
47
49
if err != nil {
48
50
return false , err
@@ -60,11 +62,11 @@ var _ = g.Describe("[networking][router] openshift routers", func() {
60
62
61
63
g .By ("waiting for the healthz endpoint to respond" )
62
64
healthzURI := fmt .Sprintf ("http://%s:1936/healthz" , routerIP )
63
- err = waitForRouterOKResponseExec (ns , execPodName , healthzURI , routerIP , 60 * 2 )
65
+ err = waitForRouterOKResponseExec (ns , execPodName , healthzURI , routerIP , changeTimeoutSeconds )
64
66
o .Expect (err ).NotTo (o .HaveOccurred ())
65
67
66
68
g .By ("waiting for the valid route to respond" )
67
- err = waitForRouterOKResponseExec (ns , execPodName , routerURL , "first.example.com" , 60 * 2 )
69
+ err = waitForRouterOKResponseExec (ns , execPodName , routerURL , "first.example.com" , changeTimeoutSeconds )
68
70
o .Expect (err ).NotTo (o .HaveOccurred ())
69
71
70
72
for _ , host := range []string {"second.example.com" , "third.example.com" } {
@@ -83,7 +85,7 @@ var _ = g.Describe("[networking][router] openshift routers", func() {
83
85
g .By (fmt .Sprintf ("creating a scoped router from a config file %q" , configPath ))
84
86
85
87
var routerIP string
86
- err := wait .Poll (time .Second , 2 * time .Minute , func () (bool , error ) {
88
+ err := wait .Poll (time .Second , changeTimeoutSeconds * time .Second , func () (bool , error ) {
87
89
pod , err := oc .KubeFramework ().ClientSet .Core ().Pods (ns ).Get ("router-override" )
88
90
if err != nil {
89
91
return false , err
@@ -103,11 +105,11 @@ var _ = g.Describe("[networking][router] openshift routers", func() {
103
105
104
106
g .By ("waiting for the healthz endpoint to respond" )
105
107
healthzURI := fmt .Sprintf ("http://%s:1936/healthz" , routerIP )
106
- err = waitForRouterOKResponseExec (ns , execPodName , healthzURI , routerIP , 60 * 2 )
108
+ err = waitForRouterOKResponseExec (ns , execPodName , healthzURI , routerIP , changeTimeoutSeconds )
107
109
o .Expect (err ).NotTo (o .HaveOccurred ())
108
110
109
111
g .By ("waiting for the valid route to respond" )
110
- err = waitForRouterOKResponseExec (ns , execPodName , routerURL , fmt .Sprintf (pattern , "route-1" , ns ), 60 * 2 )
112
+ err = waitForRouterOKResponseExec (ns , execPodName , routerURL , fmt .Sprintf (pattern , "route-1" , ns ), changeTimeoutSeconds )
111
113
o .Expect (err ).NotTo (o .HaveOccurred ())
112
114
113
115
g .By ("checking that the stored domain name does not match a route" )
0 commit comments