-
Notifications
You must be signed in to change notification settings - Fork 725
RemovePodsViolatingNodeTaints: list only pods that are not failed/suceeded #1688
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RemovePodsViolatingNodeTaints: list only pods that are not failed/suceeded #1688
Conversation
…eeded Listing pods was incorrectly changed to listing all pods during code refactoring.
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: a7i The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@ingvagabund thoughts on adding a unit test to avoid similar regression in the future? |
Field selectors are not properly implemented in the fake clientset, resp. informer built on top of a fake clientset. There would be no difference on the level of listing pods. You'd need to simulate the field selector filtering by injecting the right list of pods :(. Instead of relying on the functionality of the field selector to exclude the pods. Which is what is required here to properly test the code. The field selector filtering is kube-apiserver functionality. |
/lgtm I will add a case where the pod is in failed success phase and the eviction count is 0 in the unit test of each called plugin. |
Since I currently have limited bandwidth, I may have to wait for the weekend to work on this. |
Listing pods was incorrectly changed to listing all pods during code refactoring in 0ff8ecb#diff-494cd6260fda05699f68c7da810f7814dea797a006afee5380728a6433206fefL82.