Access control: Always append all permissions to role admin in oss (#46282)

* Always append all permissions to built in role admin in oss
This commit is contained in:
Karl Persson
2022-03-07 13:28:39 +01:00
committed by GitHub
parent 00a8542ecf
commit 0debf33c76
6 changed files with 44 additions and 18 deletions

View File

@@ -601,7 +601,7 @@ func setupAccessControlGuardianTest(t *testing.T, dashID int64, permissions []*a
require.NoError(t, err)
ac := accesscontrolmock.New().WithPermissions(permissions)
services, err := ossaccesscontrol.ProvidePermissionsServices(routing.NewRouteRegister(), store, ac, database.ProvideService(store))
services, err := ossaccesscontrol.ProvidePermissionsServices(setting.NewCfg(), routing.NewRouteRegister(), store, ac, database.ProvideService(store))
require.NoError(t, err)
return NewAccessControlDashboardGuardian(context.Background(), dashID, &models.SignedInUser{OrgId: 1}, store, ac, services)