diff --git a/pkg/auth/handlers_test.go b/pkg/auth/handlers_test.go index f52cdfbe0..4f551ed60 100644 --- a/pkg/auth/handlers_test.go +++ b/pkg/auth/handlers_test.go @@ -99,11 +99,11 @@ func TestGetMetadataEndpointRedirectHandler(t *testing.T) { ctx := context.Background() baseURL, err := url.Parse("http://www.google.com") assert.NoError(t, err) - metadataPath, err := url.Parse(OIdCMetadataEndpoint) + metadataPath, err := url.Parse(OAuth2MetadataEndpoint) assert.NoError(t, err) mockAuthCtx := mocks.AuthenticationContext{} - mockAuthCtx.On("GetBaseURL").Return(baseURL) - mockAuthCtx.On("GetMetadataURL").Return(metadataPath) + mockAuthCtx.OnGetBaseURL().Return(baseURL) + mockAuthCtx.OnGetOAuth2MetadataURL().Return(metadataPath) handler := GetOAuth2MetadataEndpointRedirectHandler(ctx, &mockAuthCtx) req, err := http.NewRequest("GET", "/xyz", nil) assert.NoError(t, err)