Disruption e2e: wait for running pods in the table test, too

This commit is contained in:
Zach Loafman 2016-11-01 10:35:34 -07:00
parent 2244bfed81
commit f8de9abf28

View File

@ -163,6 +163,11 @@ var _ = framework.KubeDescribe("DisruptionController", func() {
err = cs.Pods(ns).Evict(e)
Expect(err).Should(MatchError("Cannot evict pod as it would violate the pod's disruption budget."))
} else {
// Only wait for running pods in the "allow" case
// because one of shouldDeny cases relies on the
// replicaSet not fitting on the cluster.
waitForPodsOrDie(cs, ns, c.podCount+int(c.replicaSetSize))
// Since disruptionAllowed starts out false, if an eviction is ever allowed,
// that means the controller is working.
err = wait.PollImmediate(framework.Poll, timeout, func() (bool, error) {