forked from grafana/grafana
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsearch_service_mock.go
101 lines (79 loc) · 2.68 KB
/
search_service_mock.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
// Code generated by mockery v2.10.6. DO NOT EDIT.
package searchV2
import (
context "context"
backend "github.com/grafana/grafana-plugin-sdk-go/backend"
mock "github.com/stretchr/testify/mock"
user "github.com/grafana/grafana/pkg/services/user"
)
// MockSearchService is an autogenerated mock type for the SearchService type
type MockSearchService struct {
mock.Mock
}
// DoDashboardQuery provides a mock function with given fields: ctx, _a1, orgId, query
func (_m *MockSearchService) DoDashboardQuery(ctx context.Context, _a1 *backend.User, orgId int64, query DashboardQuery) *backend.DataResponse {
ret := _m.Called(ctx, _a1, orgId, query)
var r0 *backend.DataResponse
if rf, ok := ret.Get(0).(func(context.Context, *backend.User, int64, DashboardQuery) *backend.DataResponse); ok {
r0 = rf(ctx, _a1, orgId, query)
} else {
if ret.Get(0) != nil {
r0 = ret.Get(0).(*backend.DataResponse)
}
}
return r0
}
// IsDisabled provides a mock function with given fields:
func (_m *MockSearchService) IsDisabled() bool {
ret := _m.Called()
var r0 bool
if rf, ok := ret.Get(0).(func() bool); ok {
r0 = rf()
} else {
r0 = ret.Get(0).(bool)
}
return r0
}
// IsReady provides a mock function with given fields: ctx, orgId
func (_m *MockSearchService) IsReady(ctx context.Context, orgId int64) IsSearchReadyResponse {
ret := _m.Called(ctx, orgId)
var r0 IsSearchReadyResponse
if rf, ok := ret.Get(0).(func(context.Context, int64) IsSearchReadyResponse); ok {
r0 = rf(ctx, orgId)
} else {
r0 = ret.Get(0).(IsSearchReadyResponse)
}
return r0
}
// RegisterDashboardIndexExtender provides a mock function with given fields: ext
func (_m *MockSearchService) RegisterDashboardIndexExtender(ext DashboardIndexExtender) {
_m.Called(ext)
}
// Run provides a mock function with given fields: ctx
func (_m *MockSearchService) Run(ctx context.Context) error {
ret := _m.Called(ctx)
var r0 error
if rf, ok := ret.Get(0).(func(context.Context) error); ok {
r0 = rf(ctx)
} else {
r0 = ret.Error(0)
}
return r0
}
// TriggerReIndex provides a mock function with given fields:
func (_m *MockSearchService) TriggerReIndex() {
_m.Called()
}
// doDashboardQuery provides a mock function with given fields: ctx, _a1, orgId, query
func (_m *MockSearchService) doDashboardQuery(ctx context.Context, _a1 *user.SignedInUser, orgId int64, query DashboardQuery) *backend.DataResponse {
ret := _m.Called(ctx, _a1, orgId, query)
var r0 *backend.DataResponse
if rf, ok := ret.Get(0).(func(context.Context, *user.SignedInUser, int64, DashboardQuery) *backend.DataResponse); ok {
r0 = rf(ctx, _a1, orgId, query)
} else {
if ret.Get(0) != nil {
r0 = ret.Get(0).(*backend.DataResponse)
}
}
return r0
}