e2e: use Ginkgo context
All code must use the context from Ginkgo when doing API calls or polling for a change, otherwise the code would not return immediately when the test gets aborted.
This commit is contained in:
@@ -52,11 +52,11 @@ var _ = SIGDescribe("ImageID [NodeFeature: ImageID]", func() {
|
||||
},
|
||||
}
|
||||
|
||||
pod := e2epod.NewPodClient(f).Create(podDesc)
|
||||
pod := e2epod.NewPodClient(f).Create(ctx, podDesc)
|
||||
|
||||
framework.ExpectNoError(e2epod.WaitTimeoutForPodNoLongerRunningInNamespace(
|
||||
framework.ExpectNoError(e2epod.WaitTimeoutForPodNoLongerRunningInNamespace(ctx,
|
||||
f.ClientSet, pod.Name, f.Namespace.Name, framework.PodStartTimeout))
|
||||
runningPod, err := e2epod.NewPodClient(f).Get(context.TODO(), pod.Name, metav1.GetOptions{})
|
||||
runningPod, err := e2epod.NewPodClient(f).Get(ctx, pod.Name, metav1.GetOptions{})
|
||||
framework.ExpectNoError(err)
|
||||
|
||||
status := runningPod.Status
|
||||
|
Reference in New Issue
Block a user