Chore: Remove bus from contexthandler (#47374) (#47616)

* Chore: Remove bus from contexthandler

* fix tests

* try different wire binding

* maybe remove a few more dispatches

* fix tests

(cherry picked from commit d153d896c5)

Co-authored-by: Serge Zaitsev <serge.zaitsev@grafana.com>
This commit is contained in:
Grot (@grafanabot)
2022-04-12 12:05:27 +02:00
committed by GitHub
co-authored by Serge Zaitsev
parent 68c6e7514a
commit 556178c714
10 changed files with 33 additions and 96 deletions
@@ -40,6 +40,7 @@ type SQLStoreMock struct {
ExpectedNotifierUsageStats []*models.NotifierUsageStats
ExpectedPersistedDashboards models.HitList
ExpectedSignedInUser *models.SignedInUser
ExpectedAPIKey *models.ApiKey
ExpectedUserStars map[int64]bool
ExpectedLoginAttempts int64
@@ -622,6 +623,7 @@ func (m *SQLStoreMock) GetApiKeyById(ctx context.Context, query *models.GetApiKe
}
func (m *SQLStoreMock) GetApiKeyByName(ctx context.Context, query *models.GetApiKeyByNameQuery) error {
query.Result = m.ExpectedAPIKey
return m.ExpectedError
}