Chore: Modify patch and update of preference to take homedashboarduid than h… (#48281)

* modify patch and update of preference to take homedashboarduid than homedashboardid

* to be tested

* use getdashboard

* update doc
This commit is contained in:
ying-jeanne
2022-04-29 14:37:33 +02:00
committed by GitHub
parent 4988350160
commit 1667a7c0da
8 changed files with 230 additions and 84 deletions
+7
View File
@@ -377,6 +377,13 @@ func TestTeamAPIEndpoint_GetTeamPreferences_RBAC(t *testing.T) {
sc.db = sqlstore.InitTestDB(t)
_, err := sc.db.CreateTeam("team1", "", 1)
sqlstore := mockstore.NewSQLStoreMock()
sqlstore.ExpectedDashboard = &models.Dashboard{
Uid: "home",
Id: 1,
}
sc.hs.SQLStore = sqlstore
prefService := preftest.NewPreferenceServiceFake()
prefService.ExpectedPreference = &pref.Preference{}
sc.hs.preferenceService = prefService