github.com/mailru/activerecord@v1.12.2/pkg/octopus/mock_MockServerLogger.go (about) 1 // Code generated by mockery v2.20.0. DO NOT EDIT. 2 3 package octopus 4 5 import mock "github.com/stretchr/testify/mock" 6 7 // MockMockServerLogger is an autogenerated mock type for the MockServerLogger type 8 type MockMockServerLogger struct { 9 mock.Mock 10 } 11 12 type MockMockServerLogger_Expecter struct { 13 mock *mock.Mock 14 } 15 16 func (_m *MockMockServerLogger) EXPECT() *MockMockServerLogger_Expecter { 17 return &MockMockServerLogger_Expecter{mock: &_m.Mock} 18 } 19 20 // Debug provides a mock function with given fields: fmt, args 21 func (_m *MockMockServerLogger) Debug(fmt string, args ...interface{}) { 22 var _ca []interface{} 23 _ca = append(_ca, fmt) 24 _ca = append(_ca, args...) 25 _m.Called(_ca...) 26 } 27 28 // MockMockServerLogger_Debug_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Debug' 29 type MockMockServerLogger_Debug_Call struct { 30 *mock.Call 31 } 32 33 // Debug is a helper method to define mock.On call 34 // - fmt string 35 // - args ...interface{} 36 func (_e *MockMockServerLogger_Expecter) Debug(fmt interface{}, args ...interface{}) *MockMockServerLogger_Debug_Call { 37 return &MockMockServerLogger_Debug_Call{Call: _e.mock.On("Debug", 38 append([]interface{}{fmt}, args...)...)} 39 } 40 41 func (_c *MockMockServerLogger_Debug_Call) Run(run func(fmt string, args ...interface{})) *MockMockServerLogger_Debug_Call { 42 _c.Call.Run(func(args mock.Arguments) { 43 variadicArgs := make([]interface{}, len(args)-1) 44 for i, a := range args[1:] { 45 if a != nil { 46 variadicArgs[i] = a.(interface{}) 47 } 48 } 49 run(args[0].(string), variadicArgs...) 50 }) 51 return _c 52 } 53 54 func (_c *MockMockServerLogger_Debug_Call) Return() *MockMockServerLogger_Debug_Call { 55 _c.Call.Return() 56 return _c 57 } 58 59 func (_c *MockMockServerLogger_Debug_Call) RunAndReturn(run func(string, ...interface{})) *MockMockServerLogger_Debug_Call { 60 _c.Call.Return(run) 61 return _c 62 } 63 64 // DebugCallRequest provides a mock function with given fields: procName, args, fixtures 65 func (_m *MockMockServerLogger) DebugCallRequest(procName string, args [][]byte, fixtures ...CallMockFixture) { 66 _va := make([]interface{}, len(fixtures)) 67 for _i := range fixtures { 68 _va[_i] = fixtures[_i] 69 } 70 var _ca []interface{} 71 _ca = append(_ca, procName, args) 72 _ca = append(_ca, _va...) 73 _m.Called(_ca...) 74 } 75 76 // MockMockServerLogger_DebugCallRequest_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DebugCallRequest' 77 type MockMockServerLogger_DebugCallRequest_Call struct { 78 *mock.Call 79 } 80 81 // DebugCallRequest is a helper method to define mock.On call 82 // - procName string 83 // - args [][]byte 84 // - fixtures ...CallMockFixture 85 func (_e *MockMockServerLogger_Expecter) DebugCallRequest(procName interface{}, args interface{}, fixtures ...interface{}) *MockMockServerLogger_DebugCallRequest_Call { 86 return &MockMockServerLogger_DebugCallRequest_Call{Call: _e.mock.On("DebugCallRequest", 87 append([]interface{}{procName, args}, fixtures...)...)} 88 } 89 90 func (_c *MockMockServerLogger_DebugCallRequest_Call) Run(run func(procName string, args [][]byte, fixtures ...CallMockFixture)) *MockMockServerLogger_DebugCallRequest_Call { 91 _c.Call.Run(func(args mock.Arguments) { 92 variadicArgs := make([]CallMockFixture, len(args)-2) 93 for i, a := range args[2:] { 94 if a != nil { 95 variadicArgs[i] = a.(CallMockFixture) 96 } 97 } 98 run(args[0].(string), args[1].([][]byte), variadicArgs...) 99 }) 100 return _c 101 } 102 103 func (_c *MockMockServerLogger_DebugCallRequest_Call) Return() *MockMockServerLogger_DebugCallRequest_Call { 104 _c.Call.Return() 105 return _c 106 } 107 108 func (_c *MockMockServerLogger_DebugCallRequest_Call) RunAndReturn(run func(string, [][]byte, ...CallMockFixture)) *MockMockServerLogger_DebugCallRequest_Call { 109 _c.Call.Return(run) 110 return _c 111 } 112 113 // DebugDeleteRequest provides a mock function with given fields: ns, primaryKey, fixtures 114 func (_m *MockMockServerLogger) DebugDeleteRequest(ns uint32, primaryKey [][]byte, fixtures ...DeleteMockFixture) { 115 _va := make([]interface{}, len(fixtures)) 116 for _i := range fixtures { 117 _va[_i] = fixtures[_i] 118 } 119 var _ca []interface{} 120 _ca = append(_ca, ns, primaryKey) 121 _ca = append(_ca, _va...) 122 _m.Called(_ca...) 123 } 124 125 // MockMockServerLogger_DebugDeleteRequest_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DebugDeleteRequest' 126 type MockMockServerLogger_DebugDeleteRequest_Call struct { 127 *mock.Call 128 } 129 130 // DebugDeleteRequest is a helper method to define mock.On call 131 // - ns uint32 132 // - primaryKey [][]byte 133 // - fixtures ...DeleteMockFixture 134 func (_e *MockMockServerLogger_Expecter) DebugDeleteRequest(ns interface{}, primaryKey interface{}, fixtures ...interface{}) *MockMockServerLogger_DebugDeleteRequest_Call { 135 return &MockMockServerLogger_DebugDeleteRequest_Call{Call: _e.mock.On("DebugDeleteRequest", 136 append([]interface{}{ns, primaryKey}, fixtures...)...)} 137 } 138 139 func (_c *MockMockServerLogger_DebugDeleteRequest_Call) Run(run func(ns uint32, primaryKey [][]byte, fixtures ...DeleteMockFixture)) *MockMockServerLogger_DebugDeleteRequest_Call { 140 _c.Call.Run(func(args mock.Arguments) { 141 variadicArgs := make([]DeleteMockFixture, len(args)-2) 142 for i, a := range args[2:] { 143 if a != nil { 144 variadicArgs[i] = a.(DeleteMockFixture) 145 } 146 } 147 run(args[0].(uint32), args[1].([][]byte), variadicArgs...) 148 }) 149 return _c 150 } 151 152 func (_c *MockMockServerLogger_DebugDeleteRequest_Call) Return() *MockMockServerLogger_DebugDeleteRequest_Call { 153 _c.Call.Return() 154 return _c 155 } 156 157 func (_c *MockMockServerLogger_DebugDeleteRequest_Call) RunAndReturn(run func(uint32, [][]byte, ...DeleteMockFixture)) *MockMockServerLogger_DebugDeleteRequest_Call { 158 _c.Call.Return(run) 159 return _c 160 } 161 162 // DebugInsertRequest provides a mock function with given fields: ns, needRetVal, insertMode, tuple, fixtures 163 func (_m *MockMockServerLogger) DebugInsertRequest(ns uint32, needRetVal bool, insertMode InsertMode, tuple TupleData, fixtures ...InsertMockFixture) { 164 _va := make([]interface{}, len(fixtures)) 165 for _i := range fixtures { 166 _va[_i] = fixtures[_i] 167 } 168 var _ca []interface{} 169 _ca = append(_ca, ns, needRetVal, insertMode, tuple) 170 _ca = append(_ca, _va...) 171 _m.Called(_ca...) 172 } 173 174 // MockMockServerLogger_DebugInsertRequest_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DebugInsertRequest' 175 type MockMockServerLogger_DebugInsertRequest_Call struct { 176 *mock.Call 177 } 178 179 // DebugInsertRequest is a helper method to define mock.On call 180 // - ns uint32 181 // - needRetVal bool 182 // - insertMode InsertMode 183 // - tuple TupleData 184 // - fixtures ...InsertMockFixture 185 func (_e *MockMockServerLogger_Expecter) DebugInsertRequest(ns interface{}, needRetVal interface{}, insertMode interface{}, tuple interface{}, fixtures ...interface{}) *MockMockServerLogger_DebugInsertRequest_Call { 186 return &MockMockServerLogger_DebugInsertRequest_Call{Call: _e.mock.On("DebugInsertRequest", 187 append([]interface{}{ns, needRetVal, insertMode, tuple}, fixtures...)...)} 188 } 189 190 func (_c *MockMockServerLogger_DebugInsertRequest_Call) Run(run func(ns uint32, needRetVal bool, insertMode InsertMode, tuple TupleData, fixtures ...InsertMockFixture)) *MockMockServerLogger_DebugInsertRequest_Call { 191 _c.Call.Run(func(args mock.Arguments) { 192 variadicArgs := make([]InsertMockFixture, len(args)-4) 193 for i, a := range args[4:] { 194 if a != nil { 195 variadicArgs[i] = a.(InsertMockFixture) 196 } 197 } 198 run(args[0].(uint32), args[1].(bool), args[2].(InsertMode), args[3].(TupleData), variadicArgs...) 199 }) 200 return _c 201 } 202 203 func (_c *MockMockServerLogger_DebugInsertRequest_Call) Return() *MockMockServerLogger_DebugInsertRequest_Call { 204 _c.Call.Return() 205 return _c 206 } 207 208 func (_c *MockMockServerLogger_DebugInsertRequest_Call) RunAndReturn(run func(uint32, bool, InsertMode, TupleData, ...InsertMockFixture)) *MockMockServerLogger_DebugInsertRequest_Call { 209 _c.Call.Return(run) 210 return _c 211 } 212 213 // DebugSelectRequest provides a mock function with given fields: ns, indexnum, offset, limit, keys, fixtures 214 func (_m *MockMockServerLogger) DebugSelectRequest(ns uint32, indexnum uint32, offset uint32, limit uint32, keys [][][]byte, fixtures ...SelectMockFixture) { 215 _va := make([]interface{}, len(fixtures)) 216 for _i := range fixtures { 217 _va[_i] = fixtures[_i] 218 } 219 var _ca []interface{} 220 _ca = append(_ca, ns, indexnum, offset, limit, keys) 221 _ca = append(_ca, _va...) 222 _m.Called(_ca...) 223 } 224 225 // MockMockServerLogger_DebugSelectRequest_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DebugSelectRequest' 226 type MockMockServerLogger_DebugSelectRequest_Call struct { 227 *mock.Call 228 } 229 230 // DebugSelectRequest is a helper method to define mock.On call 231 // - ns uint32 232 // - indexnum uint32 233 // - offset uint32 234 // - limit uint32 235 // - keys [][][]byte 236 // - fixtures ...SelectMockFixture 237 func (_e *MockMockServerLogger_Expecter) DebugSelectRequest(ns interface{}, indexnum interface{}, offset interface{}, limit interface{}, keys interface{}, fixtures ...interface{}) *MockMockServerLogger_DebugSelectRequest_Call { 238 return &MockMockServerLogger_DebugSelectRequest_Call{Call: _e.mock.On("DebugSelectRequest", 239 append([]interface{}{ns, indexnum, offset, limit, keys}, fixtures...)...)} 240 } 241 242 func (_c *MockMockServerLogger_DebugSelectRequest_Call) Run(run func(ns uint32, indexnum uint32, offset uint32, limit uint32, keys [][][]byte, fixtures ...SelectMockFixture)) *MockMockServerLogger_DebugSelectRequest_Call { 243 _c.Call.Run(func(args mock.Arguments) { 244 variadicArgs := make([]SelectMockFixture, len(args)-5) 245 for i, a := range args[5:] { 246 if a != nil { 247 variadicArgs[i] = a.(SelectMockFixture) 248 } 249 } 250 run(args[0].(uint32), args[1].(uint32), args[2].(uint32), args[3].(uint32), args[4].([][][]byte), variadicArgs...) 251 }) 252 return _c 253 } 254 255 func (_c *MockMockServerLogger_DebugSelectRequest_Call) Return() *MockMockServerLogger_DebugSelectRequest_Call { 256 _c.Call.Return() 257 return _c 258 } 259 260 func (_c *MockMockServerLogger_DebugSelectRequest_Call) RunAndReturn(run func(uint32, uint32, uint32, uint32, [][][]byte, ...SelectMockFixture)) *MockMockServerLogger_DebugSelectRequest_Call { 261 _c.Call.Return(run) 262 return _c 263 } 264 265 // DebugUpdateRequest provides a mock function with given fields: ns, primaryKey, updateOps, fixtures 266 func (_m *MockMockServerLogger) DebugUpdateRequest(ns uint32, primaryKey [][]byte, updateOps []Ops, fixtures ...UpdateMockFixture) { 267 _va := make([]interface{}, len(fixtures)) 268 for _i := range fixtures { 269 _va[_i] = fixtures[_i] 270 } 271 var _ca []interface{} 272 _ca = append(_ca, ns, primaryKey, updateOps) 273 _ca = append(_ca, _va...) 274 _m.Called(_ca...) 275 } 276 277 // MockMockServerLogger_DebugUpdateRequest_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DebugUpdateRequest' 278 type MockMockServerLogger_DebugUpdateRequest_Call struct { 279 *mock.Call 280 } 281 282 // DebugUpdateRequest is a helper method to define mock.On call 283 // - ns uint32 284 // - primaryKey [][]byte 285 // - updateOps []Ops 286 // - fixtures ...UpdateMockFixture 287 func (_e *MockMockServerLogger_Expecter) DebugUpdateRequest(ns interface{}, primaryKey interface{}, updateOps interface{}, fixtures ...interface{}) *MockMockServerLogger_DebugUpdateRequest_Call { 288 return &MockMockServerLogger_DebugUpdateRequest_Call{Call: _e.mock.On("DebugUpdateRequest", 289 append([]interface{}{ns, primaryKey, updateOps}, fixtures...)...)} 290 } 291 292 func (_c *MockMockServerLogger_DebugUpdateRequest_Call) Run(run func(ns uint32, primaryKey [][]byte, updateOps []Ops, fixtures ...UpdateMockFixture)) *MockMockServerLogger_DebugUpdateRequest_Call { 293 _c.Call.Run(func(args mock.Arguments) { 294 variadicArgs := make([]UpdateMockFixture, len(args)-3) 295 for i, a := range args[3:] { 296 if a != nil { 297 variadicArgs[i] = a.(UpdateMockFixture) 298 } 299 } 300 run(args[0].(uint32), args[1].([][]byte), args[2].([]Ops), variadicArgs...) 301 }) 302 return _c 303 } 304 305 func (_c *MockMockServerLogger_DebugUpdateRequest_Call) Return() *MockMockServerLogger_DebugUpdateRequest_Call { 306 _c.Call.Return() 307 return _c 308 } 309 310 func (_c *MockMockServerLogger_DebugUpdateRequest_Call) RunAndReturn(run func(uint32, [][]byte, []Ops, ...UpdateMockFixture)) *MockMockServerLogger_DebugUpdateRequest_Call { 311 _c.Call.Return(run) 312 return _c 313 } 314 315 type mockConstructorTestingTNewMockMockServerLogger interface { 316 mock.TestingT 317 Cleanup(func()) 318 } 319 320 // NewMockMockServerLogger creates a new instance of MockMockServerLogger. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. 321 func NewMockMockServerLogger(t mockConstructorTestingTNewMockMockServerLogger) *MockMockServerLogger { 322 mock := &MockMockServerLogger{} 323 mock.Mock.Test(t) 324 325 t.Cleanup(func() { mock.AssertExpectations(t) }) 326 327 return mock 328 }