mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
chore(services): replace dependencies on dashboard store with dashboard service (#63937)
* chore(services): replace dependencies on dashboard store with dashboard service This continues the backend service/store split by replacing dashboard store dependencies with service dependencies. the folder service remains the single exception for now; otherwise we'd have a dependency cycle between the folder and dashboard services. I have some ideas for that, but I'll take care of all the easy parts first. While doing this, I identified and removed a number of unused arguments from the following functions: NewFolderNameScopeResolver NewFolderIDScopeResolver NewFolderUIDScopeResolver NewDashboardIDScopeResolver NewDashboardUIDScopeResolver resolveDashboardScope I have a small enterprise PR to support this commit. * lingering fmt
This commit is contained in:
@@ -294,9 +294,8 @@ func createDashboard(t *testing.T, sqlStore db.DB, user user.SignedInUser, dash
|
||||
ac := acmock.New()
|
||||
folderPermissions := acmock.NewMockedPermissionsService()
|
||||
dashboardPermissions := acmock.NewMockedPermissionsService()
|
||||
folderStore := folderimpl.ProvideDashboardFolderStore(sqlStore)
|
||||
service := dashboardservice.ProvideDashboardService(
|
||||
cfg, dashboardStore, folderStore, dashAlertExtractor,
|
||||
cfg, dashboardStore, dashAlertExtractor,
|
||||
features, folderPermissions, dashboardPermissions, ac,
|
||||
foldertest.NewFakeService(),
|
||||
)
|
||||
@@ -442,7 +441,7 @@ func testScenario(t *testing.T, desc string, fn func(t *testing.T, sc scenarioCo
|
||||
dashboardPermissions := acmock.NewMockedPermissionsService()
|
||||
folderStore := folderimpl.ProvideDashboardFolderStore(sqlStore)
|
||||
dashboardService := dashboardservice.ProvideDashboardService(
|
||||
sqlStore.Cfg, dashboardStore, folderStore, nil,
|
||||
sqlStore.Cfg, dashboardStore, nil,
|
||||
features, folderPermissions, dashboardPermissions, ac,
|
||||
foldertest.NewFakeService(),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user