mirror of
https://github.com/kubernetes-sigs/descheduler.git
synced 2026-01-26 05:14:13 +01:00
refactor: add SetSystemCriticalPriority helper function
This commit is contained in:
@@ -137,12 +137,9 @@ func TestDeletePodsViolatingNodeTaints(t *testing.T) {
|
|||||||
p6 := buildTestPodWithNormalOwnerRef("p6", nodeName1, nil)
|
p6 := buildTestPodWithNormalOwnerRef("p6", nodeName1, nil)
|
||||||
p7 := buildTestPodWithNormalOwnerRef("p7", nodeName2, func(pod *v1.Pod) {
|
p7 := buildTestPodWithNormalOwnerRef("p7", nodeName2, func(pod *v1.Pod) {
|
||||||
pod.Namespace = "kube-system"
|
pod.Namespace = "kube-system"
|
||||||
priority := utils.SystemCriticalPriority
|
test.SetPodPriority(pod, utils.SystemCriticalPriority)
|
||||||
pod.Spec.Priority = &priority
|
|
||||||
})
|
|
||||||
p8 := buildTestPod("p8", nodeName2, func(pod *v1.Pod) {
|
|
||||||
pod.ObjectMeta.OwnerReferences = test.GetDaemonSetOwnerRefList()
|
|
||||||
})
|
})
|
||||||
|
p8 := buildTestPod("p8", nodeName2, test.SetDSOwnerRef)
|
||||||
p9 := buildTestPodWithNormalOwnerRef("p9", nodeName2, func(pod *v1.Pod) {
|
p9 := buildTestPodWithNormalOwnerRef("p9", nodeName2, func(pod *v1.Pod) {
|
||||||
pod.Spec.Volumes = []v1.Volume{
|
pod.Spec.Volumes = []v1.Volume{
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user