-
Notifications
You must be signed in to change notification settings - Fork 132
/
mock_executorapi.go
216 lines (185 loc) · 7.9 KB
/
mock_executorapi.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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/armadaproject/armada/pkg/executorapi (interfaces: ExecutorApiClient,ExecutorApi_LeaseJobRunsClient)
// Package mocks is a generated GoMock package.
package mocks
import (
context "context"
reflect "reflect"
executorapi "github.com/armadaproject/armada/pkg/executorapi"
types "github.com/gogo/protobuf/types"
gomock "github.com/golang/mock/gomock"
grpc "google.golang.org/grpc"
metadata "google.golang.org/grpc/metadata"
)
// MockExecutorApiClient is a mock of ExecutorApiClient interface.
type MockExecutorApiClient struct {
ctrl *gomock.Controller
recorder *MockExecutorApiClientMockRecorder
}
// MockExecutorApiClientMockRecorder is the mock recorder for MockExecutorApiClient.
type MockExecutorApiClientMockRecorder struct {
mock *MockExecutorApiClient
}
// NewMockExecutorApiClient creates a new mock instance.
func NewMockExecutorApiClient(ctrl *gomock.Controller) *MockExecutorApiClient {
mock := &MockExecutorApiClient{ctrl: ctrl}
mock.recorder = &MockExecutorApiClientMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockExecutorApiClient) EXPECT() *MockExecutorApiClientMockRecorder {
return m.recorder
}
// LeaseJobRuns mocks base method.
func (m *MockExecutorApiClient) LeaseJobRuns(arg0 context.Context, arg1 ...grpc.CallOption) (executorapi.ExecutorApi_LeaseJobRunsClient, error) {
m.ctrl.T.Helper()
varargs := []interface{}{arg0}
for _, a := range arg1 {
varargs = append(varargs, a)
}
ret := m.ctrl.Call(m, "LeaseJobRuns", varargs...)
ret0, _ := ret[0].(executorapi.ExecutorApi_LeaseJobRunsClient)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// LeaseJobRuns indicates an expected call of LeaseJobRuns.
func (mr *MockExecutorApiClientMockRecorder) LeaseJobRuns(arg0 interface{}, arg1 ...interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
varargs := append([]interface{}{arg0}, arg1...)
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "LeaseJobRuns", reflect.TypeOf((*MockExecutorApiClient)(nil).LeaseJobRuns), varargs...)
}
// ReportEvents mocks base method.
func (m *MockExecutorApiClient) ReportEvents(arg0 context.Context, arg1 *executorapi.EventList, arg2 ...grpc.CallOption) (*types.Empty, error) {
m.ctrl.T.Helper()
varargs := []interface{}{arg0, arg1}
for _, a := range arg2 {
varargs = append(varargs, a)
}
ret := m.ctrl.Call(m, "ReportEvents", varargs...)
ret0, _ := ret[0].(*types.Empty)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// ReportEvents indicates an expected call of ReportEvents.
func (mr *MockExecutorApiClientMockRecorder) ReportEvents(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
varargs := append([]interface{}{arg0, arg1}, arg2...)
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReportEvents", reflect.TypeOf((*MockExecutorApiClient)(nil).ReportEvents), varargs...)
}
// MockExecutorApi_LeaseJobRunsClient is a mock of ExecutorApi_LeaseJobRunsClient interface.
type MockExecutorApi_LeaseJobRunsClient struct {
ctrl *gomock.Controller
recorder *MockExecutorApi_LeaseJobRunsClientMockRecorder
}
// MockExecutorApi_LeaseJobRunsClientMockRecorder is the mock recorder for MockExecutorApi_LeaseJobRunsClient.
type MockExecutorApi_LeaseJobRunsClientMockRecorder struct {
mock *MockExecutorApi_LeaseJobRunsClient
}
// NewMockExecutorApi_LeaseJobRunsClient creates a new mock instance.
func NewMockExecutorApi_LeaseJobRunsClient(ctrl *gomock.Controller) *MockExecutorApi_LeaseJobRunsClient {
mock := &MockExecutorApi_LeaseJobRunsClient{ctrl: ctrl}
mock.recorder = &MockExecutorApi_LeaseJobRunsClientMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockExecutorApi_LeaseJobRunsClient) EXPECT() *MockExecutorApi_LeaseJobRunsClientMockRecorder {
return m.recorder
}
// CloseSend mocks base method.
func (m *MockExecutorApi_LeaseJobRunsClient) CloseSend() error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "CloseSend")
ret0, _ := ret[0].(error)
return ret0
}
// CloseSend indicates an expected call of CloseSend.
func (mr *MockExecutorApi_LeaseJobRunsClientMockRecorder) CloseSend() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseSend", reflect.TypeOf((*MockExecutorApi_LeaseJobRunsClient)(nil).CloseSend))
}
// Context mocks base method.
func (m *MockExecutorApi_LeaseJobRunsClient) Context() context.Context {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Context")
ret0, _ := ret[0].(context.Context)
return ret0
}
// Context indicates an expected call of Context.
func (mr *MockExecutorApi_LeaseJobRunsClientMockRecorder) Context() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Context", reflect.TypeOf((*MockExecutorApi_LeaseJobRunsClient)(nil).Context))
}
// Header mocks base method.
func (m *MockExecutorApi_LeaseJobRunsClient) Header() (metadata.MD, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Header")
ret0, _ := ret[0].(metadata.MD)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Header indicates an expected call of Header.
func (mr *MockExecutorApi_LeaseJobRunsClientMockRecorder) Header() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Header", reflect.TypeOf((*MockExecutorApi_LeaseJobRunsClient)(nil).Header))
}
// Recv mocks base method.
func (m *MockExecutorApi_LeaseJobRunsClient) Recv() (*executorapi.LeaseStreamMessage, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Recv")
ret0, _ := ret[0].(*executorapi.LeaseStreamMessage)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Recv indicates an expected call of Recv.
func (mr *MockExecutorApi_LeaseJobRunsClientMockRecorder) Recv() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Recv", reflect.TypeOf((*MockExecutorApi_LeaseJobRunsClient)(nil).Recv))
}
// RecvMsg mocks base method.
func (m *MockExecutorApi_LeaseJobRunsClient) RecvMsg(arg0 interface{}) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "RecvMsg", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// RecvMsg indicates an expected call of RecvMsg.
func (mr *MockExecutorApi_LeaseJobRunsClientMockRecorder) RecvMsg(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RecvMsg", reflect.TypeOf((*MockExecutorApi_LeaseJobRunsClient)(nil).RecvMsg), arg0)
}
// Send mocks base method.
func (m *MockExecutorApi_LeaseJobRunsClient) Send(arg0 *executorapi.LeaseRequest) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Send", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// Send indicates an expected call of Send.
func (mr *MockExecutorApi_LeaseJobRunsClientMockRecorder) Send(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Send", reflect.TypeOf((*MockExecutorApi_LeaseJobRunsClient)(nil).Send), arg0)
}
// SendMsg mocks base method.
func (m *MockExecutorApi_LeaseJobRunsClient) SendMsg(arg0 interface{}) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "SendMsg", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// SendMsg indicates an expected call of SendMsg.
func (mr *MockExecutorApi_LeaseJobRunsClientMockRecorder) SendMsg(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendMsg", reflect.TypeOf((*MockExecutorApi_LeaseJobRunsClient)(nil).SendMsg), arg0)
}
// Trailer mocks base method.
func (m *MockExecutorApi_LeaseJobRunsClient) Trailer() metadata.MD {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Trailer")
ret0, _ := ret[0].(metadata.MD)
return ret0
}
// Trailer indicates an expected call of Trailer.
func (mr *MockExecutorApi_LeaseJobRunsClientMockRecorder) Trailer() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Trailer", reflect.TypeOf((*MockExecutorApi_LeaseJobRunsClient)(nil).Trailer))
}