@@ -34,6 +34,9 @@ echo "Validating features for emulated_version=${emulated_version}, current_vers
34
34
rm -f " ${results_file} "
35
35
touch " ${results_file} "
36
36
37
+ # Obtain the list of features that have been removed fully and are not in scope of emulation version(e.g kubelet)
38
+ REMOVED_FEATURE_LIST=${REMOVED_FEATURE_LIST:- ' ' }
39
+
37
40
# Parse /metrics -> actual_features[featureName] = 0 or 1
38
41
declare -A actual_features
39
42
declare -A actual_stages
@@ -149,7 +152,7 @@ while IFS= read -r unversioned_feature_entry; do
149
152
done < <( echo " $unversioned_feature_stream " )
150
153
151
154
# For each "expected" feature (versioned):
152
- # - If missing from /metrics => fail unless stage==ALPHA or lock==true
155
+ # - If missing from /metrics => fail unless stage==ALPHA or lock==true or is a deprecated feature that is listed as properly removed.
153
156
# - If present & stage!=ALPHA => compare numeric value
154
157
for feature_name in " ${! expected_stage[@]} " ; do
155
158
stage=" ${expected_stage[$feature_name]} "
@@ -168,6 +171,12 @@ for feature_name in "${!expected_stage[@]}"; do
168
171
continue
169
172
fi
170
173
174
+ # Deprecated feature that was removed, these can continue. These can only be features that are not in the
175
+ # scope of compatibility version(e.g kuebelet).
176
+ if [[ " $REMOVED_FEATURE_LIST " == * " $feature_name " * ]]; then
177
+ continue
178
+ fi
179
+
171
180
echo " FAIL: expected feature gate '$feature_name ' not found in metrics (stage=${stage} , lockToDefault=${locked} )" \
172
181
>> " ${results_file} "
173
182
continue
@@ -198,6 +207,11 @@ for unversioned_feature_name in "${!expected_unversioned_stage[@]}"; do
198
207
if [[ " $unversioned_locked " == " true" ]]; then
199
208
continue
200
209
fi
210
+ # Deprecated feature that was removed, these can continue. These can only be features that are not in the
211
+ # scope of compatibility version(e.g kuebelet).
212
+ if [[ " $REMOVED_FEATURE_LIST " == * " $feature_name " * ]]; then
213
+ continue
214
+ fi
201
215
echo " FAIL: expected unversioned feature gate '$unversioned_feature_name ' not found in metrics (lockToDefault=${unversioned_locked} )" \
202
216
>> " ${results_file} "
203
217
continue
0 commit comments