Chore: Remove bus from quota (#45143)

* Remove bus from quota

* workaround

* Change ExpectedOrg ot *models.Org
This commit is contained in:
idafurjes
2022-02-10 12:42:06 +01:00
committed by GitHub
parent f2795981c6
commit 923b62ecab
8 changed files with 52 additions and 116 deletions
+3 -2
View File
@@ -29,6 +29,7 @@ type SQLStoreMock struct {
ExpectedTeamsByUser []*models.TeamDTO
ExpectedSearchOrgList []*models.OrgDTO
ExpectedDatasources []*models.DataSource
ExpectedOrg *models.Org
ExpectedError error
}
@@ -67,11 +68,11 @@ func (m *SQLStoreMock) SearchDashboardSnapshots(query *models.GetDashboardSnapsh
}
func (m *SQLStoreMock) GetOrgByName(name string) (*models.Org, error) {
return nil, m.ExpectedError
return m.ExpectedOrg, m.ExpectedError
}
func (m *SQLStoreMock) CreateOrgWithMember(name string, userID int64) (models.Org, error) {
return models.Org{}, nil
return *m.ExpectedOrg, nil
}
func (m *SQLStoreMock) UpdateOrg(ctx context.Context, cmd *models.UpdateOrgCommand) error {