-
k8s-merge-robot authored
Automatic merge from submit-queue scheduler: change phantom pod test from integration into unit test This is an effort for #24440. Why this PR? - Integration test is hard to debug. We could model the test as a unit test similar to [TestSchedulerForgetAssumedPodAfterDelete()](https://github.com/kubernetes/kubernetes/blob/132ebb091af3b625df0ad19a5975119e800bebef/plugin/pkg/scheduler/scheduler_test.go#L173). Currently the test is testing expiring case, we can change that to delete. - Add a test similar to TestSchedulerForgetAssumedPodAfterDelete() to test phantom pod. - refactor scheduler tests to share the code between TestSchedulerNoPhantomPodAfterExpire() and TestSchedulerNoPhantomPodAfterDelete() - Decouple scheduler tests from scheduler events: not to use events
e7f7a49b