mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-07 19:23:40 +00:00
Fix PodGC test when PodDisruptionConditions disabled (#118805)
* test comment should match the code in podgc * Update test/integration/podgc/podgc_test.go Co-authored-by: Michał Woźniak <mimowo@users.noreply.github.com> * test comment should match the code in podgc --------- Co-authored-by: Michał Woźniak <mimowo@users.noreply.github.com>
This commit is contained in:
parent
89b1d0ce3e
commit
ecd727e4c7
@ -159,8 +159,8 @@ func TestTerminatingOnOutOfServiceNode(t *testing.T) {
|
||||
withFinalizer: true,
|
||||
wantPhase: v1.PodFailed,
|
||||
},
|
||||
"pod has phase when PodDisruptionConditions disabled": {
|
||||
enablePodDisruptionConditions: true,
|
||||
"pod has phase unchanged when PodDisruptionConditions disabled": {
|
||||
enablePodDisruptionConditions: false,
|
||||
withFinalizer: true,
|
||||
wantPhase: v1.PodPending,
|
||||
},
|
||||
@ -244,7 +244,7 @@ func TestTerminatingOnOutOfServiceNode(t *testing.T) {
|
||||
}
|
||||
if test.withFinalizer {
|
||||
// wait until the pod phase is set as expected
|
||||
err = wait.PollImmediate(time.Second, time.Second*15, func() (bool, error) {
|
||||
err = wait.Poll(time.Second, time.Second*15, func() (bool, error) {
|
||||
var e error
|
||||
pod, e = cs.CoreV1().Pods(pod.Namespace).Get(testCtx.Ctx, pod.Name, metav1.GetOptions{})
|
||||
if e != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user