forked from cadence-workflow/cadence
-
Notifications
You must be signed in to change notification settings - Fork 0
/
mocks.go
238 lines (200 loc) · 7.29 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
// The MIT License (MIT)
// Copyright (c) 2017-2020 Uber Technologies Inc.
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
// Code generated by MockGen. DO NOT EDIT.
// Source: interface.go
// Package pagination is a generated GoMock package.
package pagination
import (
reflect "reflect"
gomock "github.com/golang/mock/gomock"
)
// MockEntity is a mock of Entity interface.
type MockEntity struct {
ctrl *gomock.Controller
recorder *MockEntityMockRecorder
}
// MockEntityMockRecorder is the mock recorder for MockEntity.
type MockEntityMockRecorder struct {
mock *MockEntity
}
// NewMockEntity creates a new mock instance.
func NewMockEntity(ctrl *gomock.Controller) *MockEntity {
mock := &MockEntity{ctrl: ctrl}
mock.recorder = &MockEntityMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockEntity) EXPECT() *MockEntityMockRecorder {
return m.recorder
}
// MockPageToken is a mock of PageToken interface.
type MockPageToken struct {
ctrl *gomock.Controller
recorder *MockPageTokenMockRecorder
}
// MockPageTokenMockRecorder is the mock recorder for MockPageToken.
type MockPageTokenMockRecorder struct {
mock *MockPageToken
}
// NewMockPageToken creates a new mock instance.
func NewMockPageToken(ctrl *gomock.Controller) *MockPageToken {
mock := &MockPageToken{ctrl: ctrl}
mock.recorder = &MockPageTokenMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockPageToken) EXPECT() *MockPageTokenMockRecorder {
return m.recorder
}
// MockIterator is a mock of Iterator interface.
type MockIterator struct {
ctrl *gomock.Controller
recorder *MockIteratorMockRecorder
}
// MockIteratorMockRecorder is the mock recorder for MockIterator.
type MockIteratorMockRecorder struct {
mock *MockIterator
}
// NewMockIterator creates a new mock instance.
func NewMockIterator(ctrl *gomock.Controller) *MockIterator {
mock := &MockIterator{ctrl: ctrl}
mock.recorder = &MockIteratorMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockIterator) EXPECT() *MockIteratorMockRecorder {
return m.recorder
}
// HasNext mocks base method.
func (m *MockIterator) HasNext() bool {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "HasNext")
ret0, _ := ret[0].(bool)
return ret0
}
// HasNext indicates an expected call of HasNext.
func (mr *MockIteratorMockRecorder) HasNext() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "HasNext", reflect.TypeOf((*MockIterator)(nil).HasNext))
}
// Next mocks base method.
func (m *MockIterator) Next() (Entity, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Next")
ret0, _ := ret[0].(Entity)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Next indicates an expected call of Next.
func (mr *MockIteratorMockRecorder) Next() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Next", reflect.TypeOf((*MockIterator)(nil).Next))
}
// MockWriter is a mock of Writer interface.
type MockWriter struct {
ctrl *gomock.Controller
recorder *MockWriterMockRecorder
}
// MockWriterMockRecorder is the mock recorder for MockWriter.
type MockWriterMockRecorder struct {
mock *MockWriter
}
// NewMockWriter creates a new mock instance.
func NewMockWriter(ctrl *gomock.Controller) *MockWriter {
mock := &MockWriter{ctrl: ctrl}
mock.recorder = &MockWriterMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockWriter) EXPECT() *MockWriterMockRecorder {
return m.recorder
}
// Add mocks base method.
func (m *MockWriter) Add(arg0 Entity) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Add", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// Add indicates an expected call of Add.
func (mr *MockWriterMockRecorder) Add(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Add", reflect.TypeOf((*MockWriter)(nil).Add), arg0)
}
// FirstFlushedPage mocks base method.
func (m *MockWriter) FirstFlushedPage() PageToken {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "FirstFlushedPage")
ret0, _ := ret[0].(PageToken)
return ret0
}
// FirstFlushedPage indicates an expected call of FirstFlushedPage.
func (mr *MockWriterMockRecorder) FirstFlushedPage() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FirstFlushedPage", reflect.TypeOf((*MockWriter)(nil).FirstFlushedPage))
}
// Flush mocks base method.
func (m *MockWriter) Flush() error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Flush")
ret0, _ := ret[0].(error)
return ret0
}
// Flush indicates an expected call of Flush.
func (mr *MockWriterMockRecorder) Flush() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Flush", reflect.TypeOf((*MockWriter)(nil).Flush))
}
// FlushIfNotEmpty mocks base method.
func (m *MockWriter) FlushIfNotEmpty() error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "FlushIfNotEmpty")
ret0, _ := ret[0].(error)
return ret0
}
// FlushIfNotEmpty indicates an expected call of FlushIfNotEmpty.
func (mr *MockWriterMockRecorder) FlushIfNotEmpty() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FlushIfNotEmpty", reflect.TypeOf((*MockWriter)(nil).FlushIfNotEmpty))
}
// FlushedPages mocks base method.
func (m *MockWriter) FlushedPages() []PageToken {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "FlushedPages")
ret0, _ := ret[0].([]PageToken)
return ret0
}
// FlushedPages indicates an expected call of FlushedPages.
func (mr *MockWriterMockRecorder) FlushedPages() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FlushedPages", reflect.TypeOf((*MockWriter)(nil).FlushedPages))
}
// LastFlushedPage mocks base method.
func (m *MockWriter) LastFlushedPage() PageToken {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "LastFlushedPage")
ret0, _ := ret[0].(PageToken)
return ret0
}
// LastFlushedPage indicates an expected call of LastFlushedPage.
func (mr *MockWriterMockRecorder) LastFlushedPage() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "LastFlushedPage", reflect.TypeOf((*MockWriter)(nil).LastFlushedPage))
}