Access Control: Add test flag to enable access control (#46780)

* Add feature flags options to test db
This commit is contained in:
Karl Persson
2022-03-22 20:48:32 +01:00
committed by GitHub
parent 552b447946
commit ee9badecdf
6 changed files with 47 additions and 33 deletions
+2 -4
View File
@@ -61,8 +61,7 @@ func TestSQLStore_GetOrgUsers(t *testing.T) {
},
}
store := InitTestDB(t)
store.Cfg.IsFeatureToggleEnabled = featuremgmt.WithFeatures(featuremgmt.FlagAccesscontrol).IsEnabled
store := InitTestDB(t, InitTestDBOpt{FeatureFlags: []string{featuremgmt.FlagAccesscontrol}})
seedOrgUsers(t, store, 10)
for _, tt := range tests {
@@ -127,8 +126,7 @@ func TestSQLStore_SearchOrgUsers(t *testing.T) {
},
}
store := InitTestDB(t)
store.Cfg.IsFeatureToggleEnabled = featuremgmt.WithFeatures(featuremgmt.FlagAccesscontrol).IsEnabled
store := InitTestDB(t, InitTestDBOpt{FeatureFlags: []string{featuremgmt.FlagAccesscontrol}})
seedOrgUsers(t, store, 10)
for _, tt := range tests {