@@ -70,18 +70,6 @@ func TestPolicyOptionsAvailable(t *testing.T) {
70
70
featureGateEnable : true ,
71
71
expectedAvailable : false ,
72
72
},
73
- {
74
- option : FullPCPUsOnlyOption ,
75
- featureGate : pkgfeatures .CPUManagerPolicyBetaOptions ,
76
- featureGateEnable : true ,
77
- expectedAvailable : true ,
78
- },
79
- {
80
- option : FullPCPUsOnlyOption ,
81
- featureGate : pkgfeatures .CPUManagerPolicyBetaOptions ,
82
- featureGateEnable : false ,
83
- expectedAvailable : false ,
84
- },
85
73
{
86
74
option : AlignBySocketOption ,
87
75
featureGate : pkgfeatures .CPUManagerPolicyAlphaOptions ,
@@ -143,6 +131,21 @@ func TestPolicyOptionsAvailable(t *testing.T) {
143
131
}
144
132
}
145
133
134
+ func TestPolicyOptionsAlwaysAvailableOnceGA (t * testing.T ) {
135
+ options := []string {
136
+ FullPCPUsOnlyOption ,
137
+ }
138
+ for _ , option := range options {
139
+ t .Run (option , func (t * testing.T ) {
140
+ featuregatetesting .SetFeatureGateDuringTest (t , utilfeature .DefaultFeatureGate , pkgfeatures .CPUManagerPolicyAlphaOptions , false )
141
+ featuregatetesting .SetFeatureGateDuringTest (t , utilfeature .DefaultFeatureGate , pkgfeatures .CPUManagerPolicyBetaOptions , false )
142
+ if err := CheckPolicyOptionAvailable (option ); err != nil {
143
+ t .Errorf ("option %q should be available even with all featuregate disabled" , option )
144
+ }
145
+ })
146
+ }
147
+ }
148
+
146
149
func TestValidateStaticPolicyOptions (t * testing.T ) {
147
150
testCases := []struct {
148
151
description string
0 commit comments