mirror of
https://github.com/kubernetes-sigs/descheduler.git
synced 2026-01-26 05:14:13 +01:00
refactor: replace pod.Spec.Priority with test.SetPodPriority in plugin tests
This commit is contained in:
@@ -167,8 +167,7 @@ func TestFindDuplicatePods(t *testing.T) {
|
||||
}),
|
||||
buildTestPodForNode("p7", nodeName1, func(pod *v1.Pod) {
|
||||
pod.Namespace = "kube-system"
|
||||
priority := utils.SystemCriticalPriority
|
||||
pod.Spec.Priority = &priority
|
||||
test.SetPodPriority(pod, utils.SystemCriticalPriority)
|
||||
}),
|
||||
},
|
||||
nodes: []*v1.Node{
|
||||
@@ -205,8 +204,7 @@ func TestFindDuplicatePods(t *testing.T) {
|
||||
}),
|
||||
buildTestPodForNode("p7", nodeName1, func(pod *v1.Pod) {
|
||||
pod.Namespace = "kube-system"
|
||||
priority := utils.SystemCriticalPriority
|
||||
pod.Spec.Priority = &priority
|
||||
test.SetPodPriority(pod, utils.SystemCriticalPriority)
|
||||
}),
|
||||
buildTestPodWithRSOwnerRefWithNamespaceForNode1("p8", "test", nil),
|
||||
buildTestPodWithRSOwnerRefWithNamespaceForNode1("p9", "test", nil),
|
||||
|
||||
Reference in New Issue
Block a user