promote HonorPVReclaimPolicy to GA

Signed-off-by: carlory <baofa.fan@daocloud.io>
This commit is contained in:
carlory
2025-01-13 16:04:20 +08:00
parent a18b4a8d97
commit 28d359beec
9 changed files with 39 additions and 56 deletions

View File

@@ -22,6 +22,7 @@ import (
v1 "k8s.io/api/core/v1"
storage "k8s.io/api/storage/v1"
"k8s.io/apimachinery/pkg/util/version"
utilfeature "k8s.io/apiserver/pkg/util/feature"
featuregatetesting "k8s.io/component-base/featuregate/testing"
"k8s.io/component-helpers/storage/volume"
@@ -37,6 +38,8 @@ import (
func TestDeleteSync(t *testing.T) {
const gceDriver = "pd.csi.storage.gke.io"
// Default enable the HonorPVReclaimPolicy feature gate.
// TODO: this will be removed in 1.36
featuregatetesting.SetFeatureGateEmulationVersionDuringTest(t, utilfeature.DefaultFeatureGate, version.MustParse("1.32"))
featuregatetesting.SetFeatureGateDuringTest(t, utilfeature.DefaultFeatureGate, features.HonorPVReclaimPolicy, true)
_, ctx := ktesting.NewTestContext(t)
tests := []controllerTest{