Cleanup defer from SetFeatureGateDuringTest function call

This commit is contained in:
Marek Siarkowicz
2024-04-23 10:39:47 +02:00
committed by Marek Siarkowicz
parent bf6507070c
commit 3ee8178768
187 changed files with 547 additions and 565 deletions

View File

@@ -237,7 +237,7 @@ func TestToKubeContainerStatus(t *testing.T) {
// TestToKubeContainerStatusWithResources tests the converting the CRI container status to
// the internal type (i.e., toKubeContainerStatus()) for containers that returns Resources.
func TestToKubeContainerStatusWithResources(t *testing.T) {
defer featuregatetesting.SetFeatureGateDuringTest(t, utilfeature.DefaultFeatureGate, features.InPlacePodVerticalScaling, true)()
featuregatetesting.SetFeatureGateDuringTest(t, utilfeature.DefaultFeatureGate, features.InPlacePodVerticalScaling, true)
cid := &kubecontainer.ContainerID{Type: "testRuntime", ID: "dummyid"}
meta := &runtimeapi.ContainerMetadata{Name: "cname", Attempt: 3}
imageSpec := &runtimeapi.ImageSpec{Image: "fimage"}