-
Notifications
You must be signed in to change notification settings - Fork 22
/
mocks.go
302 lines (253 loc) · 10.7 KB
/
mocks.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
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
// Code generated by MockGen. DO NOT EDIT.
// Source: code.vegaprotocol.io/vega/core/staking (interfaces: EvtForwarder,EthereumClientConfirmations,EthereumEventSource,TimeService,EthConfirmations,EthOnChainVerifier,Witness)
// Package mocks is a generated GoMock package.
package mocks
import (
context "context"
big "math/big"
reflect "reflect"
time "time"
types "code.vegaprotocol.io/vega/core/types"
validators "code.vegaprotocol.io/vega/core/validators"
v1 "code.vegaprotocol.io/vega/protos/vega/commands/v1"
types0 "github.com/ethereum/go-ethereum/core/types"
gomock "github.com/golang/mock/gomock"
)
// MockEvtForwarder is a mock of EvtForwarder interface.
type MockEvtForwarder struct {
ctrl *gomock.Controller
recorder *MockEvtForwarderMockRecorder
}
// MockEvtForwarderMockRecorder is the mock recorder for MockEvtForwarder.
type MockEvtForwarderMockRecorder struct {
mock *MockEvtForwarder
}
// NewMockEvtForwarder creates a new mock instance.
func NewMockEvtForwarder(ctrl *gomock.Controller) *MockEvtForwarder {
mock := &MockEvtForwarder{ctrl: ctrl}
mock.recorder = &MockEvtForwarderMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockEvtForwarder) EXPECT() *MockEvtForwarderMockRecorder {
return m.recorder
}
// ForwardFromSelf mocks base method.
func (m *MockEvtForwarder) ForwardFromSelf(arg0 *v1.ChainEvent) {
m.ctrl.T.Helper()
m.ctrl.Call(m, "ForwardFromSelf", arg0)
}
// ForwardFromSelf indicates an expected call of ForwardFromSelf.
func (mr *MockEvtForwarderMockRecorder) ForwardFromSelf(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ForwardFromSelf", reflect.TypeOf((*MockEvtForwarder)(nil).ForwardFromSelf), arg0)
}
// MockEthereumClientConfirmations is a mock of EthereumClientConfirmations interface.
type MockEthereumClientConfirmations struct {
ctrl *gomock.Controller
recorder *MockEthereumClientConfirmationsMockRecorder
}
// MockEthereumClientConfirmationsMockRecorder is the mock recorder for MockEthereumClientConfirmations.
type MockEthereumClientConfirmationsMockRecorder struct {
mock *MockEthereumClientConfirmations
}
// NewMockEthereumClientConfirmations creates a new mock instance.
func NewMockEthereumClientConfirmations(ctrl *gomock.Controller) *MockEthereumClientConfirmations {
mock := &MockEthereumClientConfirmations{ctrl: ctrl}
mock.recorder = &MockEthereumClientConfirmationsMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockEthereumClientConfirmations) EXPECT() *MockEthereumClientConfirmationsMockRecorder {
return m.recorder
}
// HeaderByNumber mocks base method.
func (m *MockEthereumClientConfirmations) HeaderByNumber(arg0 context.Context, arg1 *big.Int) (*types0.Header, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "HeaderByNumber", arg0, arg1)
ret0, _ := ret[0].(*types0.Header)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// HeaderByNumber indicates an expected call of HeaderByNumber.
func (mr *MockEthereumClientConfirmationsMockRecorder) HeaderByNumber(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "HeaderByNumber", reflect.TypeOf((*MockEthereumClientConfirmations)(nil).HeaderByNumber), arg0, arg1)
}
// MockEthereumEventSource is a mock of EthereumEventSource interface.
type MockEthereumEventSource struct {
ctrl *gomock.Controller
recorder *MockEthereumEventSourceMockRecorder
}
// MockEthereumEventSourceMockRecorder is the mock recorder for MockEthereumEventSource.
type MockEthereumEventSourceMockRecorder struct {
mock *MockEthereumEventSource
}
// NewMockEthereumEventSource creates a new mock instance.
func NewMockEthereumEventSource(ctrl *gomock.Controller) *MockEthereumEventSource {
mock := &MockEthereumEventSource{ctrl: ctrl}
mock.recorder = &MockEthereumEventSourceMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockEthereumEventSource) EXPECT() *MockEthereumEventSourceMockRecorder {
return m.recorder
}
// UpdateStakingStartingBlock mocks base method.
func (m *MockEthereumEventSource) UpdateStakingStartingBlock(arg0 uint64) {
m.ctrl.T.Helper()
m.ctrl.Call(m, "UpdateStakingStartingBlock", arg0)
}
// UpdateStakingStartingBlock indicates an expected call of UpdateStakingStartingBlock.
func (mr *MockEthereumEventSourceMockRecorder) UpdateStakingStartingBlock(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateStakingStartingBlock", reflect.TypeOf((*MockEthereumEventSource)(nil).UpdateStakingStartingBlock), arg0)
}
// MockTimeService is a mock of TimeService interface.
type MockTimeService struct {
ctrl *gomock.Controller
recorder *MockTimeServiceMockRecorder
}
// MockTimeServiceMockRecorder is the mock recorder for MockTimeService.
type MockTimeServiceMockRecorder struct {
mock *MockTimeService
}
// NewMockTimeService creates a new mock instance.
func NewMockTimeService(ctrl *gomock.Controller) *MockTimeService {
mock := &MockTimeService{ctrl: ctrl}
mock.recorder = &MockTimeServiceMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockTimeService) EXPECT() *MockTimeServiceMockRecorder {
return m.recorder
}
// GetTimeNow mocks base method.
func (m *MockTimeService) GetTimeNow() time.Time {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "GetTimeNow")
ret0, _ := ret[0].(time.Time)
return ret0
}
// GetTimeNow indicates an expected call of GetTimeNow.
func (mr *MockTimeServiceMockRecorder) GetTimeNow() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetTimeNow", reflect.TypeOf((*MockTimeService)(nil).GetTimeNow))
}
// MockEthConfirmations is a mock of EthConfirmations interface.
type MockEthConfirmations struct {
ctrl *gomock.Controller
recorder *MockEthConfirmationsMockRecorder
}
// MockEthConfirmationsMockRecorder is the mock recorder for MockEthConfirmations.
type MockEthConfirmationsMockRecorder struct {
mock *MockEthConfirmations
}
// NewMockEthConfirmations creates a new mock instance.
func NewMockEthConfirmations(ctrl *gomock.Controller) *MockEthConfirmations {
mock := &MockEthConfirmations{ctrl: ctrl}
mock.recorder = &MockEthConfirmationsMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockEthConfirmations) EXPECT() *MockEthConfirmationsMockRecorder {
return m.recorder
}
// Check mocks base method.
func (m *MockEthConfirmations) Check(arg0 uint64) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Check", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// Check indicates an expected call of Check.
func (mr *MockEthConfirmationsMockRecorder) Check(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Check", reflect.TypeOf((*MockEthConfirmations)(nil).Check), arg0)
}
// MockEthOnChainVerifier is a mock of EthOnChainVerifier interface.
type MockEthOnChainVerifier struct {
ctrl *gomock.Controller
recorder *MockEthOnChainVerifierMockRecorder
}
// MockEthOnChainVerifierMockRecorder is the mock recorder for MockEthOnChainVerifier.
type MockEthOnChainVerifierMockRecorder struct {
mock *MockEthOnChainVerifier
}
// NewMockEthOnChainVerifier creates a new mock instance.
func NewMockEthOnChainVerifier(ctrl *gomock.Controller) *MockEthOnChainVerifier {
mock := &MockEthOnChainVerifier{ctrl: ctrl}
mock.recorder = &MockEthOnChainVerifierMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockEthOnChainVerifier) EXPECT() *MockEthOnChainVerifierMockRecorder {
return m.recorder
}
// CheckStakeDeposited mocks base method.
func (m *MockEthOnChainVerifier) CheckStakeDeposited(arg0 *types.StakeDeposited) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "CheckStakeDeposited", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// CheckStakeDeposited indicates an expected call of CheckStakeDeposited.
func (mr *MockEthOnChainVerifierMockRecorder) CheckStakeDeposited(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CheckStakeDeposited", reflect.TypeOf((*MockEthOnChainVerifier)(nil).CheckStakeDeposited), arg0)
}
// CheckStakeRemoved mocks base method.
func (m *MockEthOnChainVerifier) CheckStakeRemoved(arg0 *types.StakeRemoved) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "CheckStakeRemoved", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// CheckStakeRemoved indicates an expected call of CheckStakeRemoved.
func (mr *MockEthOnChainVerifierMockRecorder) CheckStakeRemoved(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CheckStakeRemoved", reflect.TypeOf((*MockEthOnChainVerifier)(nil).CheckStakeRemoved), arg0)
}
// MockWitness is a mock of Witness interface.
type MockWitness struct {
ctrl *gomock.Controller
recorder *MockWitnessMockRecorder
}
// MockWitnessMockRecorder is the mock recorder for MockWitness.
type MockWitnessMockRecorder struct {
mock *MockWitness
}
// NewMockWitness creates a new mock instance.
func NewMockWitness(ctrl *gomock.Controller) *MockWitness {
mock := &MockWitness{ctrl: ctrl}
mock.recorder = &MockWitnessMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockWitness) EXPECT() *MockWitnessMockRecorder {
return m.recorder
}
// RestoreResource mocks base method.
func (m *MockWitness) RestoreResource(arg0 validators.Resource, arg1 func(interface{}, bool)) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "RestoreResource", arg0, arg1)
ret0, _ := ret[0].(error)
return ret0
}
// RestoreResource indicates an expected call of RestoreResource.
func (mr *MockWitnessMockRecorder) RestoreResource(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RestoreResource", reflect.TypeOf((*MockWitness)(nil).RestoreResource), arg0, arg1)
}
// StartCheck mocks base method.
func (m *MockWitness) StartCheck(arg0 validators.Resource, arg1 func(interface{}, bool), arg2 time.Time) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "StartCheck", arg0, arg1, arg2)
ret0, _ := ret[0].(error)
return ret0
}
// StartCheck indicates an expected call of StartCheck.
func (mr *MockWitnessMockRecorder) StartCheck(arg0, arg1, arg2 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "StartCheck", reflect.TypeOf((*MockWitness)(nil).StartCheck), arg0, arg1, arg2)
}