From d010c0febb8746599d7c96011e14d4a9c204e429 Mon Sep 17 00:00:00 2001 From: Andreas Sommer Date: Thu, 19 Dec 2024 13:29:51 +0100 Subject: [PATCH] Fix usage of changed `utilfeature.SetFeatureGateDuringTest` signature --- api/v1beta2/awscluster_webhook_test.go | 2 +- api/v1beta2/awsmachine_webhook_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/api/v1beta2/awscluster_webhook_test.go b/api/v1beta2/awscluster_webhook_test.go index 41bc5d3b1c..18c0352f91 100644 --- a/api/v1beta2/awscluster_webhook_test.go +++ b/api/v1beta2/awscluster_webhook_test.go @@ -663,7 +663,7 @@ func TestAWSClusterValidateCreate(t *testing.T) { } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { - defer utilfeature.SetFeatureGateDuringTest(t, feature.Gates, feature.BootstrapFormatIgnition, true)() + utilfeature.SetFeatureGateDuringTest(t, feature.Gates, feature.BootstrapFormatIgnition, true) cluster := tt.cluster.DeepCopy() cluster.ObjectMeta = metav1.ObjectMeta{ diff --git a/api/v1beta2/awsmachine_webhook_test.go b/api/v1beta2/awsmachine_webhook_test.go index 80e7abc45a..30c84e587e 100644 --- a/api/v1beta2/awsmachine_webhook_test.go +++ b/api/v1beta2/awsmachine_webhook_test.go @@ -439,7 +439,7 @@ func TestAWSMachineCreate(t *testing.T) { } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { - defer utilfeature.SetFeatureGateDuringTest(t, feature.Gates, feature.BootstrapFormatIgnition, true)() + utilfeature.SetFeatureGateDuringTest(t, feature.Gates, feature.BootstrapFormatIgnition, true) machine := tt.machine.DeepCopy() machine.ObjectMeta = metav1.ObjectMeta{