enforce strict alpha handling for API serving
Kubernetes-commit: 21faec925459bce93954e0f0110ebd3a4f207c24
This commit is contained in:
parent
2286099903
commit
d15d62d4df
|
|
@ -54,7 +54,10 @@ type ResourceExpirationEvaluator interface {
|
|||
}
|
||||
|
||||
func NewResourceExpirationEvaluator(currentVersion apimachineryversion.Info) (ResourceExpirationEvaluator, error) {
|
||||
ret := &resourceExpirationEvaluator{}
|
||||
ret := &resourceExpirationEvaluator{
|
||||
// TODO https://github.com/kubernetes/kubernetes/issues/101951 set this back to false after beta is tagged.
|
||||
strictRemovedHandlingInAlpha: true,
|
||||
}
|
||||
if len(currentVersion.Major) > 0 {
|
||||
currentMajor64, err := strconv.ParseInt(currentVersion.Major, 10, 32)
|
||||
if err != nil {
|
||||
|
|
|
|||
|
|
@ -82,6 +82,7 @@ func Test_newResourceExpirationEvaluator(t *testing.T) {
|
|||
return
|
||||
}
|
||||
|
||||
actual.(*resourceExpirationEvaluator).strictRemovedHandlingInAlpha = false
|
||||
if !reflect.DeepEqual(tt.expected, *actual.(*resourceExpirationEvaluator)) {
|
||||
t.Fatal(actual)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue