Documentation ¶
Overview ¶
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.
Package mocks provide mocks for grafana api clients
Index ¶
- Constants
- type Mockapi
- func (m *Mockapi) DashboardByUID(uid string) (*gapi.Dashboard, error)
- func (m *Mockapi) Dashboards() ([]gapi.FolderDashboardSearchResponse, error)
- func (m *Mockapi) DashboardsByIDs(ids []int64) ([]gapi.FolderDashboardSearchResponse, error)
- func (m *Mockapi) DataSources() ([]*gapi.DataSource, error)
- func (m *Mockapi) EXPECT() *MockapiMockRecorder
- func (m *Mockapi) Folders() ([]gapi.Folder, error)
- func (m *Mockapi) NewAlertRule(ar *gapi.AlertRule) (string, error)
- func (m *Mockapi) NewDashboard(dashboard gapi.Dashboard) (*gapi.DashboardSaveResponse, error)
- func (m *Mockapi) NewDataSource(s *gapi.DataSource) (int64, error)
- func (m *Mockapi) NewFolder(title string, uid ...string) (gapi.Folder, error)
- type MockapiMockRecorder
- func (mr *MockapiMockRecorder) DashboardByUID(uid interface{}) *gomock.Call
- func (mr *MockapiMockRecorder) Dashboards() *gomock.Call
- func (mr *MockapiMockRecorder) DashboardsByIDs(ids interface{}) *gomock.Call
- func (mr *MockapiMockRecorder) DataSources() *gomock.Call
- func (mr *MockapiMockRecorder) Folders() *gomock.Call
- func (mr *MockapiMockRecorder) NewAlertRule(ar interface{}) *gomock.Call
- func (mr *MockapiMockRecorder) NewDashboard(dashboard interface{}) *gomock.Call
- func (mr *MockapiMockRecorder) NewDataSource(s interface{}) *gomock.Call
- func (mr *MockapiMockRecorder) NewFolder(title interface{}, uid ...interface{}) *gomock.Call
- type MockcustomAPI
- type MockcustomAPIMockRecorder
Constants ¶
const SampleRulesJSON = `` /* 21919-byte string literal not displayed */
SampleRulesJSON is a JSON response for grafana rules api
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Mockapi ¶
type Mockapi struct {
// contains filtered or unexported fields
}
Mockapi is a mock of api interface.
func NewMockapi ¶
func NewMockapi(ctrl *gomock.Controller) *Mockapi
NewMockapi creates a new mock instance.
func (*Mockapi) DashboardByUID ¶
DashboardByUID mocks base method.
func (*Mockapi) Dashboards ¶
func (m *Mockapi) Dashboards() ([]gapi.FolderDashboardSearchResponse, error)
Dashboards mocks base method.
func (*Mockapi) DashboardsByIDs ¶
func (m *Mockapi) DashboardsByIDs(ids []int64) ([]gapi.FolderDashboardSearchResponse, error)
DashboardsByIDs mocks base method.
func (*Mockapi) DataSources ¶
func (m *Mockapi) DataSources() ([]*gapi.DataSource, error)
DataSources mocks base method.
func (*Mockapi) EXPECT ¶
func (m *Mockapi) EXPECT() *MockapiMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*Mockapi) NewAlertRule ¶
NewAlertRule mocks base method.
func (*Mockapi) NewDashboard ¶
NewDashboard mocks base method.
func (*Mockapi) NewDataSource ¶
func (m *Mockapi) NewDataSource(s *gapi.DataSource) (int64, error)
NewDataSource mocks base method.
type MockapiMockRecorder ¶
type MockapiMockRecorder struct {
// contains filtered or unexported fields
}
MockapiMockRecorder is the mock recorder for Mockapi.
func (*MockapiMockRecorder) DashboardByUID ¶
func (mr *MockapiMockRecorder) DashboardByUID(uid interface{}) *gomock.Call
DashboardByUID indicates an expected call of DashboardByUID.
func (*MockapiMockRecorder) Dashboards ¶
func (mr *MockapiMockRecorder) Dashboards() *gomock.Call
Dashboards indicates an expected call of Dashboards.
func (*MockapiMockRecorder) DashboardsByIDs ¶
func (mr *MockapiMockRecorder) DashboardsByIDs(ids interface{}) *gomock.Call
DashboardsByIDs indicates an expected call of DashboardsByIDs.
func (*MockapiMockRecorder) DataSources ¶
func (mr *MockapiMockRecorder) DataSources() *gomock.Call
DataSources indicates an expected call of DataSources.
func (*MockapiMockRecorder) Folders ¶
func (mr *MockapiMockRecorder) Folders() *gomock.Call
Folders indicates an expected call of Folders.
func (*MockapiMockRecorder) NewAlertRule ¶
func (mr *MockapiMockRecorder) NewAlertRule(ar interface{}) *gomock.Call
NewAlertRule indicates an expected call of NewAlertRule.
func (*MockapiMockRecorder) NewDashboard ¶
func (mr *MockapiMockRecorder) NewDashboard(dashboard interface{}) *gomock.Call
NewDashboard indicates an expected call of NewDashboard.
func (*MockapiMockRecorder) NewDataSource ¶
func (mr *MockapiMockRecorder) NewDataSource(s interface{}) *gomock.Call
NewDataSource indicates an expected call of NewDataSource.
func (*MockapiMockRecorder) NewFolder ¶
func (mr *MockapiMockRecorder) NewFolder(title interface{}, uid ...interface{}) *gomock.Call
NewFolder indicates an expected call of NewFolder.
type MockcustomAPI ¶
type MockcustomAPI struct {
// contains filtered or unexported fields
}
MockcustomAPI is a mock of customAPI interface.
func NewMockcustomAPI ¶
func NewMockcustomAPI(ctrl *gomock.Controller) *MockcustomAPI
NewMockcustomAPI creates a new mock instance.
func (*MockcustomAPI) AllRuleGroups ¶
func (m *MockcustomAPI) AllRuleGroups() (grafana.RuleGroupsByFolder, error)
AllRuleGroups mocks base method.
func (*MockcustomAPI) EXPECT ¶
func (m *MockcustomAPI) EXPECT() *MockcustomAPIMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockcustomAPIMockRecorder ¶
type MockcustomAPIMockRecorder struct {
// contains filtered or unexported fields
}
MockcustomAPIMockRecorder is the mock recorder for MockcustomAPI.
func (*MockcustomAPIMockRecorder) AllRuleGroups ¶
func (mr *MockcustomAPIMockRecorder) AllRuleGroups() *gomock.Call
AllRuleGroups indicates an expected call of AllRuleGroups.