mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 11:50:44 +00:00
Add constant PodReadyTimeout to e2e test
This commit is contained in:
parent
079764ebd5
commit
36f4527956
@ -59,6 +59,7 @@ const (
|
||||
maxBackOffTolerance = time.Duration(1.3 * float64(kubelet.MaxContainerBackOff))
|
||||
podRetryPeriod = 1 * time.Second
|
||||
podRetryTimeout = 1 * time.Minute
|
||||
podReadyTimeout = 1 * time.Minute
|
||||
)
|
||||
|
||||
// testHostIP tests that a pod gets a host IP
|
||||
@ -922,7 +923,7 @@ var _ = framework.KubeDescribe("Pods", func() {
|
||||
framework.ExpectNoError(err, "failed to create Pod %v in namespace %v", testPod.ObjectMeta.Name, testNamespaceName)
|
||||
|
||||
ginkgo.By("watching for Pod to be ready")
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 1*time.Minute)
|
||||
ctx, cancel := context.WithTimeout(context.Background(), podReadyTimeout)
|
||||
defer cancel()
|
||||
_, err = watchtools.Until(ctx, podsList.ResourceVersion, w, func(event watch.Event) (bool, error) {
|
||||
if pod, ok := event.Object.(*v1.Pod); ok {
|
||||
|
Loading…
Reference in New Issue
Block a user