From 78788d72dedc335c8c9bc36201582f89ae9c818c Mon Sep 17 00:00:00 2001 From: Jan Chaloupka Date: Mon, 15 Dec 2025 18:11:55 +0100 Subject: [PATCH] refactor(node_taint_test): inline p15 --- .../removepodsviolatingnodetaints/node_taint_test.go | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/pkg/framework/plugins/removepodsviolatingnodetaints/node_taint_test.go b/pkg/framework/plugins/removepodsviolatingnodetaints/node_taint_test.go index 43023358c..e518100c6 100644 --- a/pkg/framework/plugins/removepodsviolatingnodetaints/node_taint_test.go +++ b/pkg/framework/plugins/removepodsviolatingnodetaints/node_taint_test.go @@ -163,11 +163,6 @@ func TestDeletePodsViolatingNodeTaints(t *testing.T) { // node5 has PreferNoSchedule:testTaint1=test1, so the p13 has to have // PreferNoSchedule:testTaint0=test0 so the pod is not tolarated - p15 := buildTestPodWithNormalOwnerRef("p15", nodeName7, func(pod *v1.Pod) { - withTestTaintToleration1(pod) - addTolerationToPod(pod, "testingTaint", "testing", 1, v1.TaintEffectNoSchedule) - }) - var uint1, uint2 uint = 1, 2 tests := []struct { @@ -478,7 +473,10 @@ func TestDeletePodsViolatingNodeTaints(t *testing.T) { description: "Pods not tolerating all taints are evicted when includedTaints is empty", pods: []*v1.Pod{ buildTestPodWithNormalOwnerRef("p14", nodeName7, withTestTaintToleration1), - p15, + buildTestPodWithNormalOwnerRef("p15", nodeName7, func(pod *v1.Pod) { + withTestTaintToleration1(pod) + addTolerationToPod(pod, "testingTaint", "testing", 1, v1.TaintEffectNoSchedule) + }), }, nodes: []*v1.Node{ buildTestNode(nodeName7, withBothTaints1),