go.uber.org/cadence@v1.2.9/mocks/Client.go (about) 1 // Copyright (c) 2017 Uber Technologies, Inc. 2 // 3 // Permission is hereby granted, free of charge, to any person obtaining a copy 4 // of this software and associated documentation files (the "Software"), to deal 5 // in the Software without restriction, including without limitation the rights 6 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 // copies of the Software, and to permit persons to whom the Software is 8 // furnished to do so, subject to the following conditions: 9 // 10 // The above copyright notice and this permission notice shall be included in 11 // all copies or substantial portions of the Software. 12 // 13 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 // THE SOFTWARE. 20 21 // Code generated by mockery v2.16.0. DO NOT EDIT. 22 package mocks 23 24 import ( 25 context "context" 26 27 mock "github.com/stretchr/testify/mock" 28 29 internal "go.uber.org/cadence/internal" 30 31 shared "go.uber.org/cadence/.gen/go/shared" 32 ) 33 34 // Client is an autogenerated mock type for the Client type 35 type Client struct { 36 mock.Mock 37 } 38 39 // CancelWorkflow provides a mock function with given fields: ctx, workflowID, runID, opts 40 func (_m *Client) CancelWorkflow(ctx context.Context, workflowID string, runID string, opts ...internal.Option) error { 41 _va := make([]interface{}, len(opts)) 42 for _i := range opts { 43 _va[_i] = opts[_i] 44 } 45 var _ca []interface{} 46 _ca = append(_ca, ctx, workflowID, runID) 47 _ca = append(_ca, _va...) 48 ret := _m.Called(_ca...) 49 50 var r0 error 51 if rf, ok := ret.Get(0).(func(context.Context, string, string, ...internal.Option) error); ok { 52 r0 = rf(ctx, workflowID, runID, opts...) 53 } else { 54 r0 = ret.Error(0) 55 } 56 57 return r0 58 } 59 60 // CompleteActivity provides a mock function with given fields: ctx, taskToken, result, err 61 func (_m *Client) CompleteActivity(ctx context.Context, taskToken []byte, result interface{}, err error) error { 62 ret := _m.Called(ctx, taskToken, result, err) 63 64 var r0 error 65 if rf, ok := ret.Get(0).(func(context.Context, []byte, interface{}, error) error); ok { 66 r0 = rf(ctx, taskToken, result, err) 67 } else { 68 r0 = ret.Error(0) 69 } 70 71 return r0 72 } 73 74 // CompleteActivityByID provides a mock function with given fields: ctx, domain, workflowID, runID, activityID, result, err 75 func (_m *Client) CompleteActivityByID(ctx context.Context, domain string, workflowID string, runID string, activityID string, result interface{}, err error) error { 76 ret := _m.Called(ctx, domain, workflowID, runID, activityID, result, err) 77 78 var r0 error 79 if rf, ok := ret.Get(0).(func(context.Context, string, string, string, string, interface{}, error) error); ok { 80 r0 = rf(ctx, domain, workflowID, runID, activityID, result, err) 81 } else { 82 r0 = ret.Error(0) 83 } 84 85 return r0 86 } 87 88 // CountWorkflow provides a mock function with given fields: ctx, request 89 func (_m *Client) CountWorkflow(ctx context.Context, request *shared.CountWorkflowExecutionsRequest) (*shared.CountWorkflowExecutionsResponse, error) { 90 ret := _m.Called(ctx, request) 91 92 var r0 *shared.CountWorkflowExecutionsResponse 93 if rf, ok := ret.Get(0).(func(context.Context, *shared.CountWorkflowExecutionsRequest) *shared.CountWorkflowExecutionsResponse); ok { 94 r0 = rf(ctx, request) 95 } else { 96 if ret.Get(0) != nil { 97 r0 = ret.Get(0).(*shared.CountWorkflowExecutionsResponse) 98 } 99 } 100 101 var r1 error 102 if rf, ok := ret.Get(1).(func(context.Context, *shared.CountWorkflowExecutionsRequest) error); ok { 103 r1 = rf(ctx, request) 104 } else { 105 r1 = ret.Error(1) 106 } 107 108 return r0, r1 109 } 110 111 // DescribeTaskList provides a mock function with given fields: ctx, tasklist, tasklistType 112 func (_m *Client) DescribeTaskList(ctx context.Context, tasklist string, tasklistType shared.TaskListType) (*shared.DescribeTaskListResponse, error) { 113 ret := _m.Called(ctx, tasklist, tasklistType) 114 115 var r0 *shared.DescribeTaskListResponse 116 if rf, ok := ret.Get(0).(func(context.Context, string, shared.TaskListType) *shared.DescribeTaskListResponse); ok { 117 r0 = rf(ctx, tasklist, tasklistType) 118 } else { 119 if ret.Get(0) != nil { 120 r0 = ret.Get(0).(*shared.DescribeTaskListResponse) 121 } 122 } 123 124 var r1 error 125 if rf, ok := ret.Get(1).(func(context.Context, string, shared.TaskListType) error); ok { 126 r1 = rf(ctx, tasklist, tasklistType) 127 } else { 128 r1 = ret.Error(1) 129 } 130 131 return r0, r1 132 } 133 134 // DescribeWorkflowExecution provides a mock function with given fields: ctx, workflowID, runID 135 func (_m *Client) DescribeWorkflowExecution(ctx context.Context, workflowID string, runID string) (*shared.DescribeWorkflowExecutionResponse, error) { 136 ret := _m.Called(ctx, workflowID, runID) 137 138 var r0 *shared.DescribeWorkflowExecutionResponse 139 if rf, ok := ret.Get(0).(func(context.Context, string, string) *shared.DescribeWorkflowExecutionResponse); ok { 140 r0 = rf(ctx, workflowID, runID) 141 } else { 142 if ret.Get(0) != nil { 143 r0 = ret.Get(0).(*shared.DescribeWorkflowExecutionResponse) 144 } 145 } 146 147 var r1 error 148 if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { 149 r1 = rf(ctx, workflowID, runID) 150 } else { 151 r1 = ret.Error(1) 152 } 153 154 return r0, r1 155 } 156 157 // ExecuteWorkflow provides a mock function with given fields: ctx, options, workflow, args 158 func (_m *Client) ExecuteWorkflow(ctx context.Context, options internal.StartWorkflowOptions, workflow interface{}, args ...interface{}) (internal.WorkflowRun, error) { 159 var _ca []interface{} 160 _ca = append(_ca, ctx, options, workflow) 161 _ca = append(_ca, args...) 162 ret := _m.Called(_ca...) 163 164 var r0 internal.WorkflowRun 165 if rf, ok := ret.Get(0).(func(context.Context, internal.StartWorkflowOptions, interface{}, ...interface{}) internal.WorkflowRun); ok { 166 r0 = rf(ctx, options, workflow, args...) 167 } else { 168 if ret.Get(0) != nil { 169 r0 = ret.Get(0).(internal.WorkflowRun) 170 } 171 } 172 173 var r1 error 174 if rf, ok := ret.Get(1).(func(context.Context, internal.StartWorkflowOptions, interface{}, ...interface{}) error); ok { 175 r1 = rf(ctx, options, workflow, args...) 176 } else { 177 r1 = ret.Error(1) 178 } 179 180 return r0, r1 181 } 182 183 // GetSearchAttributes provides a mock function with given fields: ctx 184 func (_m *Client) GetSearchAttributes(ctx context.Context) (*shared.GetSearchAttributesResponse, error) { 185 ret := _m.Called(ctx) 186 187 var r0 *shared.GetSearchAttributesResponse 188 if rf, ok := ret.Get(0).(func(context.Context) *shared.GetSearchAttributesResponse); ok { 189 r0 = rf(ctx) 190 } else { 191 if ret.Get(0) != nil { 192 r0 = ret.Get(0).(*shared.GetSearchAttributesResponse) 193 } 194 } 195 196 var r1 error 197 if rf, ok := ret.Get(1).(func(context.Context) error); ok { 198 r1 = rf(ctx) 199 } else { 200 r1 = ret.Error(1) 201 } 202 203 return r0, r1 204 } 205 206 // GetWorkflow provides a mock function with given fields: ctx, workflowID, runID 207 func (_m *Client) GetWorkflow(ctx context.Context, workflowID string, runID string) internal.WorkflowRun { 208 ret := _m.Called(ctx, workflowID, runID) 209 210 var r0 internal.WorkflowRun 211 if rf, ok := ret.Get(0).(func(context.Context, string, string) internal.WorkflowRun); ok { 212 r0 = rf(ctx, workflowID, runID) 213 } else { 214 if ret.Get(0) != nil { 215 r0 = ret.Get(0).(internal.WorkflowRun) 216 } 217 } 218 219 return r0 220 } 221 222 // GetWorkflowHistory provides a mock function with given fields: ctx, workflowID, runID, isLongPoll, filterType 223 func (_m *Client) GetWorkflowHistory(ctx context.Context, workflowID string, runID string, isLongPoll bool, filterType shared.HistoryEventFilterType) internal.HistoryEventIterator { 224 ret := _m.Called(ctx, workflowID, runID, isLongPoll, filterType) 225 226 var r0 internal.HistoryEventIterator 227 if rf, ok := ret.Get(0).(func(context.Context, string, string, bool, shared.HistoryEventFilterType) internal.HistoryEventIterator); ok { 228 r0 = rf(ctx, workflowID, runID, isLongPoll, filterType) 229 } else { 230 if ret.Get(0) != nil { 231 r0 = ret.Get(0).(internal.HistoryEventIterator) 232 } 233 } 234 235 return r0 236 } 237 238 // ListArchivedWorkflow provides a mock function with given fields: ctx, request 239 func (_m *Client) ListArchivedWorkflow(ctx context.Context, request *shared.ListArchivedWorkflowExecutionsRequest) (*shared.ListArchivedWorkflowExecutionsResponse, error) { 240 ret := _m.Called(ctx, request) 241 242 var r0 *shared.ListArchivedWorkflowExecutionsResponse 243 if rf, ok := ret.Get(0).(func(context.Context, *shared.ListArchivedWorkflowExecutionsRequest) *shared.ListArchivedWorkflowExecutionsResponse); ok { 244 r0 = rf(ctx, request) 245 } else { 246 if ret.Get(0) != nil { 247 r0 = ret.Get(0).(*shared.ListArchivedWorkflowExecutionsResponse) 248 } 249 } 250 251 var r1 error 252 if rf, ok := ret.Get(1).(func(context.Context, *shared.ListArchivedWorkflowExecutionsRequest) error); ok { 253 r1 = rf(ctx, request) 254 } else { 255 r1 = ret.Error(1) 256 } 257 258 return r0, r1 259 } 260 261 // ListClosedWorkflow provides a mock function with given fields: ctx, request 262 func (_m *Client) ListClosedWorkflow(ctx context.Context, request *shared.ListClosedWorkflowExecutionsRequest) (*shared.ListClosedWorkflowExecutionsResponse, error) { 263 ret := _m.Called(ctx, request) 264 265 var r0 *shared.ListClosedWorkflowExecutionsResponse 266 if rf, ok := ret.Get(0).(func(context.Context, *shared.ListClosedWorkflowExecutionsRequest) *shared.ListClosedWorkflowExecutionsResponse); ok { 267 r0 = rf(ctx, request) 268 } else { 269 if ret.Get(0) != nil { 270 r0 = ret.Get(0).(*shared.ListClosedWorkflowExecutionsResponse) 271 } 272 } 273 274 var r1 error 275 if rf, ok := ret.Get(1).(func(context.Context, *shared.ListClosedWorkflowExecutionsRequest) error); ok { 276 r1 = rf(ctx, request) 277 } else { 278 r1 = ret.Error(1) 279 } 280 281 return r0, r1 282 } 283 284 // ListOpenWorkflow provides a mock function with given fields: ctx, request 285 func (_m *Client) ListOpenWorkflow(ctx context.Context, request *shared.ListOpenWorkflowExecutionsRequest) (*shared.ListOpenWorkflowExecutionsResponse, error) { 286 ret := _m.Called(ctx, request) 287 288 var r0 *shared.ListOpenWorkflowExecutionsResponse 289 if rf, ok := ret.Get(0).(func(context.Context, *shared.ListOpenWorkflowExecutionsRequest) *shared.ListOpenWorkflowExecutionsResponse); ok { 290 r0 = rf(ctx, request) 291 } else { 292 if ret.Get(0) != nil { 293 r0 = ret.Get(0).(*shared.ListOpenWorkflowExecutionsResponse) 294 } 295 } 296 297 var r1 error 298 if rf, ok := ret.Get(1).(func(context.Context, *shared.ListOpenWorkflowExecutionsRequest) error); ok { 299 r1 = rf(ctx, request) 300 } else { 301 r1 = ret.Error(1) 302 } 303 304 return r0, r1 305 } 306 307 // ListWorkflow provides a mock function with given fields: ctx, request 308 func (_m *Client) ListWorkflow(ctx context.Context, request *shared.ListWorkflowExecutionsRequest) (*shared.ListWorkflowExecutionsResponse, error) { 309 ret := _m.Called(ctx, request) 310 311 var r0 *shared.ListWorkflowExecutionsResponse 312 if rf, ok := ret.Get(0).(func(context.Context, *shared.ListWorkflowExecutionsRequest) *shared.ListWorkflowExecutionsResponse); ok { 313 r0 = rf(ctx, request) 314 } else { 315 if ret.Get(0) != nil { 316 r0 = ret.Get(0).(*shared.ListWorkflowExecutionsResponse) 317 } 318 } 319 320 var r1 error 321 if rf, ok := ret.Get(1).(func(context.Context, *shared.ListWorkflowExecutionsRequest) error); ok { 322 r1 = rf(ctx, request) 323 } else { 324 r1 = ret.Error(1) 325 } 326 327 return r0, r1 328 } 329 330 // QueryWorkflow provides a mock function with given fields: ctx, workflowID, runID, queryType, args 331 func (_m *Client) QueryWorkflow(ctx context.Context, workflowID string, runID string, queryType string, args ...interface{}) (internal.Value, error) { 332 var _ca []interface{} 333 _ca = append(_ca, ctx, workflowID, runID, queryType) 334 _ca = append(_ca, args...) 335 ret := _m.Called(_ca...) 336 337 var r0 internal.Value 338 if rf, ok := ret.Get(0).(func(context.Context, string, string, string, ...interface{}) internal.Value); ok { 339 r0 = rf(ctx, workflowID, runID, queryType, args...) 340 } else { 341 if ret.Get(0) != nil { 342 r0 = ret.Get(0).(internal.Value) 343 } 344 } 345 346 var r1 error 347 if rf, ok := ret.Get(1).(func(context.Context, string, string, string, ...interface{}) error); ok { 348 r1 = rf(ctx, workflowID, runID, queryType, args...) 349 } else { 350 r1 = ret.Error(1) 351 } 352 353 return r0, r1 354 } 355 356 // QueryWorkflowWithOptions provides a mock function with given fields: ctx, request 357 func (_m *Client) QueryWorkflowWithOptions(ctx context.Context, request *internal.QueryWorkflowWithOptionsRequest) (*internal.QueryWorkflowWithOptionsResponse, error) { 358 ret := _m.Called(ctx, request) 359 360 var r0 *internal.QueryWorkflowWithOptionsResponse 361 if rf, ok := ret.Get(0).(func(context.Context, *internal.QueryWorkflowWithOptionsRequest) *internal.QueryWorkflowWithOptionsResponse); ok { 362 r0 = rf(ctx, request) 363 } else { 364 if ret.Get(0) != nil { 365 r0 = ret.Get(0).(*internal.QueryWorkflowWithOptionsResponse) 366 } 367 } 368 369 var r1 error 370 if rf, ok := ret.Get(1).(func(context.Context, *internal.QueryWorkflowWithOptionsRequest) error); ok { 371 r1 = rf(ctx, request) 372 } else { 373 r1 = ret.Error(1) 374 } 375 376 return r0, r1 377 } 378 379 // RecordActivityHeartbeat provides a mock function with given fields: ctx, taskToken, details 380 func (_m *Client) RecordActivityHeartbeat(ctx context.Context, taskToken []byte, details ...interface{}) error { 381 var _ca []interface{} 382 _ca = append(_ca, ctx, taskToken) 383 _ca = append(_ca, details...) 384 ret := _m.Called(_ca...) 385 386 var r0 error 387 if rf, ok := ret.Get(0).(func(context.Context, []byte, ...interface{}) error); ok { 388 r0 = rf(ctx, taskToken, details...) 389 } else { 390 r0 = ret.Error(0) 391 } 392 393 return r0 394 } 395 396 // RecordActivityHeartbeatByID provides a mock function with given fields: ctx, domain, workflowID, runID, activityID, details 397 func (_m *Client) RecordActivityHeartbeatByID(ctx context.Context, domain string, workflowID string, runID string, activityID string, details ...interface{}) error { 398 var _ca []interface{} 399 _ca = append(_ca, ctx, domain, workflowID, runID, activityID) 400 _ca = append(_ca, details...) 401 ret := _m.Called(_ca...) 402 403 var r0 error 404 if rf, ok := ret.Get(0).(func(context.Context, string, string, string, string, ...interface{}) error); ok { 405 r0 = rf(ctx, domain, workflowID, runID, activityID, details...) 406 } else { 407 r0 = ret.Error(0) 408 } 409 410 return r0 411 } 412 413 // RefreshWorkflowTasks provides a mock function with given fields: ctx, workflowID, runID 414 func (_m *Client) RefreshWorkflowTasks(ctx context.Context, workflowID string, runID string) error { 415 ret := _m.Called(ctx, workflowID, runID) 416 417 var r0 error 418 if rf, ok := ret.Get(0).(func(context.Context, string, string) error); ok { 419 r0 = rf(ctx, workflowID, runID) 420 } else { 421 r0 = ret.Error(0) 422 } 423 424 return r0 425 } 426 427 // ResetWorkflow provides a mock function with given fields: ctx, request 428 func (_m *Client) ResetWorkflow(ctx context.Context, request *shared.ResetWorkflowExecutionRequest) (*shared.ResetWorkflowExecutionResponse, error) { 429 ret := _m.Called(ctx, request) 430 431 var r0 *shared.ResetWorkflowExecutionResponse 432 if rf, ok := ret.Get(0).(func(context.Context, *shared.ResetWorkflowExecutionRequest) *shared.ResetWorkflowExecutionResponse); ok { 433 r0 = rf(ctx, request) 434 } else { 435 if ret.Get(0) != nil { 436 r0 = ret.Get(0).(*shared.ResetWorkflowExecutionResponse) 437 } 438 } 439 440 var r1 error 441 if rf, ok := ret.Get(1).(func(context.Context, *shared.ResetWorkflowExecutionRequest) error); ok { 442 r1 = rf(ctx, request) 443 } else { 444 r1 = ret.Error(1) 445 } 446 447 return r0, r1 448 } 449 450 // ScanWorkflow provides a mock function with given fields: ctx, request 451 func (_m *Client) ScanWorkflow(ctx context.Context, request *shared.ListWorkflowExecutionsRequest) (*shared.ListWorkflowExecutionsResponse, error) { 452 ret := _m.Called(ctx, request) 453 454 var r0 *shared.ListWorkflowExecutionsResponse 455 if rf, ok := ret.Get(0).(func(context.Context, *shared.ListWorkflowExecutionsRequest) *shared.ListWorkflowExecutionsResponse); ok { 456 r0 = rf(ctx, request) 457 } else { 458 if ret.Get(0) != nil { 459 r0 = ret.Get(0).(*shared.ListWorkflowExecutionsResponse) 460 } 461 } 462 463 var r1 error 464 if rf, ok := ret.Get(1).(func(context.Context, *shared.ListWorkflowExecutionsRequest) error); ok { 465 r1 = rf(ctx, request) 466 } else { 467 r1 = ret.Error(1) 468 } 469 470 return r0, r1 471 } 472 473 // SignalWithStartWorkflow provides a mock function with given fields: ctx, workflowID, signalName, signalArg, options, workflowFunc, workflowArgs 474 func (_m *Client) SignalWithStartWorkflow(ctx context.Context, workflowID string, signalName string, signalArg interface{}, options internal.StartWorkflowOptions, workflowFunc interface{}, workflowArgs ...interface{}) (*internal.WorkflowExecution, error) { 475 var _ca []interface{} 476 _ca = append(_ca, ctx, workflowID, signalName, signalArg, options, workflowFunc) 477 _ca = append(_ca, workflowArgs...) 478 ret := _m.Called(_ca...) 479 480 var r0 *internal.WorkflowExecution 481 if rf, ok := ret.Get(0).(func(context.Context, string, string, interface{}, internal.StartWorkflowOptions, interface{}, ...interface{}) *internal.WorkflowExecution); ok { 482 r0 = rf(ctx, workflowID, signalName, signalArg, options, workflowFunc, workflowArgs...) 483 } else { 484 if ret.Get(0) != nil { 485 r0 = ret.Get(0).(*internal.WorkflowExecution) 486 } 487 } 488 489 var r1 error 490 if rf, ok := ret.Get(1).(func(context.Context, string, string, interface{}, internal.StartWorkflowOptions, interface{}, ...interface{}) error); ok { 491 r1 = rf(ctx, workflowID, signalName, signalArg, options, workflowFunc, workflowArgs...) 492 } else { 493 r1 = ret.Error(1) 494 } 495 496 return r0, r1 497 } 498 499 // SignalWorkflow provides a mock function with given fields: ctx, workflowID, runID, signalName, arg 500 func (_m *Client) SignalWorkflow(ctx context.Context, workflowID string, runID string, signalName string, arg interface{}) error { 501 ret := _m.Called(ctx, workflowID, runID, signalName, arg) 502 503 var r0 error 504 if rf, ok := ret.Get(0).(func(context.Context, string, string, string, interface{}) error); ok { 505 r0 = rf(ctx, workflowID, runID, signalName, arg) 506 } else { 507 r0 = ret.Error(0) 508 } 509 510 return r0 511 } 512 513 // StartWorkflow provides a mock function with given fields: ctx, options, workflowFunc, args 514 func (_m *Client) StartWorkflow(ctx context.Context, options internal.StartWorkflowOptions, workflowFunc interface{}, args ...interface{}) (*internal.WorkflowExecution, error) { 515 var _ca []interface{} 516 _ca = append(_ca, ctx, options, workflowFunc) 517 _ca = append(_ca, args...) 518 ret := _m.Called(_ca...) 519 520 var r0 *internal.WorkflowExecution 521 if rf, ok := ret.Get(0).(func(context.Context, internal.StartWorkflowOptions, interface{}, ...interface{}) *internal.WorkflowExecution); ok { 522 r0 = rf(ctx, options, workflowFunc, args...) 523 } else { 524 if ret.Get(0) != nil { 525 r0 = ret.Get(0).(*internal.WorkflowExecution) 526 } 527 } 528 529 var r1 error 530 if rf, ok := ret.Get(1).(func(context.Context, internal.StartWorkflowOptions, interface{}, ...interface{}) error); ok { 531 r1 = rf(ctx, options, workflowFunc, args...) 532 } else { 533 r1 = ret.Error(1) 534 } 535 536 return r0, r1 537 } 538 539 // TerminateWorkflow provides a mock function with given fields: ctx, workflowID, runID, reason, details 540 func (_m *Client) TerminateWorkflow(ctx context.Context, workflowID string, runID string, reason string, details []byte) error { 541 ret := _m.Called(ctx, workflowID, runID, reason, details) 542 543 var r0 error 544 if rf, ok := ret.Get(0).(func(context.Context, string, string, string, []byte) error); ok { 545 r0 = rf(ctx, workflowID, runID, reason, details) 546 } else { 547 r0 = ret.Error(0) 548 } 549 550 return r0 551 } 552 553 type mockConstructorTestingTNewClient interface { 554 mock.TestingT 555 Cleanup(func()) 556 } 557 558 // NewClient creates a new instance of Client. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. 559 func NewClient(t mockConstructorTestingTNewClient) *Client { 560 mock := &Client{} 561 mock.Mock.Test(t) 562 563 t.Cleanup(func() { mock.AssertExpectations(t) }) 564 565 return mock 566 }