GetCodespace calls GetCodespaceFunc.
(ctx context.Context, name string, includeConnection bool)
| 454 | |
| 455 | // GetCodespace calls GetCodespaceFunc. |
| 456 | func (mock *apiClientMock) GetCodespace(ctx context.Context, name string, includeConnection bool) (*codespacesAPI.Codespace, error) { |
| 457 | if mock.GetCodespaceFunc == nil { |
| 458 | panic("apiClientMock.GetCodespaceFunc: method is nil but apiClient.GetCodespace was just called") |
| 459 | } |
| 460 | callInfo := struct { |
| 461 | Ctx context.Context |
| 462 | Name string |
| 463 | IncludeConnection bool |
| 464 | }{ |
| 465 | Ctx: ctx, |
| 466 | Name: name, |
| 467 | IncludeConnection: includeConnection, |
| 468 | } |
| 469 | mock.lockGetCodespace.Lock() |
| 470 | mock.calls.GetCodespace = append(mock.calls.GetCodespace, callInfo) |
| 471 | mock.lockGetCodespace.Unlock() |
| 472 | return mock.GetCodespaceFunc(ctx, name, includeConnection) |
| 473 | } |
| 474 | |
| 475 | // GetCodespaceCalls gets all the calls that were made to GetCodespace. |
| 476 | // Check the length with: |
nothing calls this directly
no outgoing calls
no test coverage detected