using wait.PollUntilContextTimeout instead of deprecated wait.Poll/PollWithContext/PollImmediate/PollImmediateWithContext methods for scheduler

This commit is contained in:
SataQiu
2023-08-24 18:35:59 +08:00
parent 02e51b27a9
commit 5524f1651a
5 changed files with 6 additions and 6 deletions

View File

@@ -326,7 +326,7 @@ var _ = SIGDescribe("LimitRange", func() {
framework.ExpectNoError(err, "failed to delete the LimitRange by Collection")
ginkgo.By(fmt.Sprintf("Confirm that the limitRange %q has been deleted", lrName))
err = wait.PollImmediateWithContext(ctx, 1*time.Second, 10*time.Second, checkLimitRangeListQuantity(f, patchedLabelSelector, 0))
err = wait.PollUntilContextTimeout(ctx, 1*time.Second, 10*time.Second, true, checkLimitRangeListQuantity(f, patchedLabelSelector, 0))
framework.ExpectNoError(err, "failed to count the required limitRanges")
framework.Logf("LimitRange %q has been deleted.", lrName)