@@ -40,11 +40,6 @@ func TestGetDrainTimeout(t *testing.T) {
4040 },
4141 CreatedAt : time .Now ().UTC (),
4242 }
43- h := DrainNodeHandler {
44- log : log ,
45- cfg : drainNodeConfig {},
46- }
47-
4843 timeout := k8s .GetDrainTimeout (action )
4944
5045 // We give some wiggle room as the test might get here a few milliseconds late.
@@ -62,10 +57,6 @@ func TestGetDrainTimeout(t *testing.T) {
6257 },
6358 CreatedAt : time .Now ().UTC ().Add (- 3 * time .Minute ),
6459 }
65- h := DrainNodeHandler {
66- log : log ,
67- cfg : drainNodeConfig {},
68- }
6960
7061 timeout := k8s .GetDrainTimeout (action )
7162 r .Less (int (math .Floor (timeout .Seconds ())), 600 )
@@ -82,10 +73,6 @@ func TestGetDrainTimeout(t *testing.T) {
8273 },
8374 CreatedAt : time .Now ().UTC ().Add (- 60 * time .Minute ),
8475 }
85- h := DrainNodeHandler {
86- log : log ,
87- cfg : drainNodeConfig {},
88- }
8976
9077 timeout := k8s .GetDrainTimeout (action )
9178 r .Equal (0 , int (timeout .Seconds ()))
@@ -776,7 +763,6 @@ func TestShouldWaitForVolumeDetach(t *testing.T) {
776763 for _ , tt := range tests {
777764 t .Run (tt .name , func (t * testing.T ) {
778765 t .Parallel ()
779- h := & DrainNodeHandler {}
780766 req := & castai.ActionDrainNode {
781767 WaitForVolumeDetach : tt .waitForVolumeDetach ,
782768 }
0 commit comments