Skip to content

Commit

Permalink
Fix format
Browse files Browse the repository at this point in the history
Signed-off-by: Israel Blancas <[email protected]>
  • Loading branch information
iblancasa committed Dec 11, 2023
1 parent 5f1ba44 commit 160fec2
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions pkg/autodetect/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -501,28 +501,28 @@ func TestAutoDetectAutoscalingVersion(t *testing.T) {
b = WithClients(cl, dcl, cl)
dcl.ServerGroupsFunc = func() (apiGroupList *metav1.APIGroupList, err error) {
return &metav1.APIGroupList{
Groups: []metav1.APIGroup{
{
Name: v1.FlagAutoscalingVersionV2,
Groups: []metav1.APIGroup{
{
Name: v1.FlagAutoscalingVersionV2,
Versions: []metav1.GroupVersionForDiscovery{
{Version: v1.FlagAutoscalingVersionV2},
},
},
{
Name: v1.FlagAutoscalingVersionV2Beta2,
Versions: []metav1.GroupVersionForDiscovery{
{Version: v1.FlagAutoscalingVersionV2Beta2},
},
},
},
},
{
Name: v1.FlagAutoscalingVersionV2Beta2,
Versions: []metav1.GroupVersionForDiscovery{
{Version: v1.FlagAutoscalingVersionV2Beta2},
},
},
},
}, nil
}

dcl.ServerResourcesForGroupVersionFunc = func(requestedApiVersion string) (apiGroupList *metav1.APIResourceList, err error) {
if requestedApiVersion == v1.FlagAutoscalingVersionV2 {
apiResourceList := &metav1.APIResourceList{GroupVersion: v1.FlagAutoscalingVersionV2, APIResources: []metav1.APIResource{{Name: "horizontalpodautoscalers"}}}
return apiResourceList, nil
} else if (requestedApiVersion == v1.FlagAutoscalingVersionV2Beta2) {
} else if requestedApiVersion == v1.FlagAutoscalingVersionV2Beta2 {
apiResourceList := &metav1.APIResourceList{GroupVersion: v1.FlagAutoscalingVersionV2Beta2, APIResources: []metav1.APIResource{{Name: "horizontalpodautoscalers"}}}
return apiResourceList, nil
}
Expand All @@ -534,7 +534,7 @@ func TestAutoDetectAutoscalingVersion(t *testing.T) {

// verify
assert.Equal(t, v1.FlagAutoscalingVersionV2, viper.GetString(v1.FlagAutoscalingVersion))

}

func TestSkipAuthDelegatorNonOpenShift(t *testing.T) {
Expand Down

0 comments on commit 160fec2

Please sign in to comment.