mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-06 10:43:56 +00:00
Fix an "index out of bound" issue in scheduler preemption e2e
This commit is contained in:
parent
5ceddce539
commit
517a41fe84
@ -214,14 +214,14 @@ var _ = SIGDescribe("SchedulerPreemption [Serial]", func() {
|
|||||||
if len(pods) == 0 {
|
if len(pods) == 0 {
|
||||||
priorityName = lowPriorityClassName
|
priorityName = lowPriorityClassName
|
||||||
}
|
}
|
||||||
pods[i] = createPausePod(f, pausePodConfig{
|
pods = append(pods, createPausePod(f, pausePodConfig{
|
||||||
Name: fmt.Sprintf("pod%d-%v", i, priorityName),
|
Name: fmt.Sprintf("pod%d-%v", i, priorityName),
|
||||||
PriorityClassName: priorityName,
|
PriorityClassName: priorityName,
|
||||||
Resources: &v1.ResourceRequirements{
|
Resources: &v1.ResourceRequirements{
|
||||||
Requests: podRes,
|
Requests: podRes,
|
||||||
},
|
},
|
||||||
NodeName: node.Name,
|
NodeName: node.Name,
|
||||||
})
|
}))
|
||||||
framework.Logf("Created pod: %v", pods[i].Name)
|
framework.Logf("Created pod: %v", pods[i].Name)
|
||||||
}
|
}
|
||||||
if len(pods) < 2 {
|
if len(pods) < 2 {
|
||||||
|
Loading…
Reference in New Issue
Block a user