Auth: Remove ssoSettingsApi feature toggle (#107528)

* Remove ssoSettingsApi feature toggle

* Clean up

* lint

* Fix tests
This commit is contained in:
Misi
2025-07-03 10:53:33 +02:00
committed by GitHub
parent e076c74869
commit a7bfd8e351
33 changed files with 265 additions and 201 deletions

View File

@ -56,7 +56,7 @@ func ProvideService(cfg *setting.Cfg, features featuremgmt.FeatureToggles, ssoSe
ssoSettings: ssoSettings,
}
if s.features.IsEnabledGlobally(featuremgmt.FlagSsoSettingsApi) && s.features.IsEnabledGlobally(featuremgmt.FlagSsoSettingsLDAP) {
if s.features.IsEnabledGlobally(featuremgmt.FlagSsoSettingsLDAP) {
s.ssoSettings.RegisterReloadable(social.LDAPProviderName, s)
ldapSettings, err := s.ssoSettings.GetForProvider(context.Background(), social.LDAPProviderName)

View File

@ -6,7 +6,6 @@ import (
"sync"
"testing"
"github.com/grafana/grafana/pkg/services/featuremgmt"
"github.com/grafana/grafana/pkg/services/ldap"
"github.com/grafana/grafana/pkg/services/ssosettings/models"
"github.com/stretchr/testify/require"
@ -309,7 +308,6 @@ func TestReload(t *testing.T) {
for _, tt := range testCases {
t.Run(tt.description, func(t *testing.T) {
ldapImpl := &LDAPImpl{
features: featuremgmt.WithManager(featuremgmt.FlagSsoSettingsApi),
loadingMutex: &sync.Mutex{},
}
@ -544,7 +542,6 @@ func TestValidate(t *testing.T) {
for _, tt := range testCases {
t.Run(tt.description, func(t *testing.T) {
ldapImpl := &LDAPImpl{
features: featuremgmt.WithManager(featuremgmt.FlagSsoSettingsApi),
loadingMutex: &sync.Mutex{},
}