mirror of
https://github.com/grafana/grafana.git
synced 2025-08-02 23:42:51 +08:00
PublicDashboards: Middleware creation (#77941)
This commit is contained in:
@ -273,7 +273,8 @@ func TestHTTPServer_DeleteDashboardByUID_AccessControl(t *testing.T) {
|
||||
|
||||
pubDashService := publicdashboards.NewFakePublicDashboardService(t)
|
||||
pubDashService.On("DeleteByDashboard", mock.Anything, mock.Anything).Return(nil).Maybe()
|
||||
hs.PublicDashboardsApi = api.ProvideApi(pubDashService, nil, hs.AccessControl, featuremgmt.WithFeatures())
|
||||
middleware := publicdashboards.NewFakePublicDashboardMiddleware(t)
|
||||
hs.PublicDashboardsApi = api.ProvideApi(pubDashService, nil, hs.AccessControl, featuremgmt.WithFeatures(), middleware)
|
||||
|
||||
guardian.InitAccessControlGuardian(hs.Cfg, hs.AccessControl, hs.DashboardService)
|
||||
})
|
||||
|
Reference in New Issue
Block a user