Fix bad sleep - int as duration
This commit is contained in:
		@@ -1928,7 +1928,7 @@ func execSourceipTest(f *framework.Framework, c clientset.Interface, ns, nodeNam
 | 
				
			|||||||
	timeout := 2 * time.Minute
 | 
						timeout := 2 * time.Minute
 | 
				
			||||||
	framework.Logf("Waiting up to %v wget %s", timeout, serviceIPPort)
 | 
						framework.Logf("Waiting up to %v wget %s", timeout, serviceIPPort)
 | 
				
			||||||
	cmd := fmt.Sprintf(`wget -T 30 -qO- %s | grep client_address`, serviceIPPort)
 | 
						cmd := fmt.Sprintf(`wget -T 30 -qO- %s | grep client_address`, serviceIPPort)
 | 
				
			||||||
	for start := time.Now(); time.Since(start) < timeout; time.Sleep(2) {
 | 
						for start := time.Now(); time.Since(start) < timeout; time.Sleep(2 * time.Second) {
 | 
				
			||||||
		stdout, err = framework.RunHostCmd(execPod.Namespace, execPod.Name, cmd)
 | 
							stdout, err = framework.RunHostCmd(execPod.Namespace, execPod.Name, cmd)
 | 
				
			||||||
		if err != nil {
 | 
							if err != nil {
 | 
				
			||||||
			framework.Logf("got err: %v, retry until timeout", err)
 | 
								framework.Logf("got err: %v, retry until timeout", err)
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user