diff --git a/kafkamgmt/apiv1/client/api/openapi.yaml b/kafkamgmt/apiv1/client/api/openapi.yaml index c40803b9..b3d65bd4 100644 --- a/kafkamgmt/apiv1/client/api/openapi.yaml +++ b/kafkamgmt/apiv1/client/api/openapi.yaml @@ -1852,7 +1852,6 @@ components: required: - capacity - enabled - - supported_instance_types ServiceAccount: allOf: - $ref: '#/components/schemas/ObjectReference' diff --git a/kafkamgmt/apiv1/client/docs/CloudRegion.md b/kafkamgmt/apiv1/client/docs/CloudRegion.md index b8f054f4..0cbf2f89 100644 --- a/kafkamgmt/apiv1/client/docs/CloudRegion.md +++ b/kafkamgmt/apiv1/client/docs/CloudRegion.md @@ -15,7 +15,7 @@ Name | Type | Description | Notes ### NewCloudRegion -`func NewCloudRegion(enabled bool, supportedInstanceTypes []string, capacity []RegionCapacityListItem, ) *CloudRegion` +`func NewCloudRegion(enabled bool, capacity []RegionCapacityListItem, ) *CloudRegion` NewCloudRegion instantiates a new CloudRegion object This constructor will assign default values to properties that have it defined, diff --git a/kafkamgmt/apiv1/client/errors_api_mock.go b/kafkamgmt/apiv1/client/errors_api_mock.go new file mode 100644 index 00000000..3f2820b3 --- /dev/null +++ b/kafkamgmt/apiv1/client/errors_api_mock.go @@ -0,0 +1,210 @@ +// Code generated by moq; DO NOT EDIT. +// github.com/matryer/moq + +package kafkamgmtclient + +import ( + _context "context" + _nethttp "net/http" + "sync" +) + +// Ensure, that ErrorsApiMock does implement ErrorsApi. +// If this is not the case, regenerate this file with moq. +var _ ErrorsApi = &ErrorsApiMock{} + +// ErrorsApiMock is a mock implementation of ErrorsApi. +// +// func TestSomethingThatUsesErrorsApi(t *testing.T) { +// +// // make and configure a mocked ErrorsApi +// mockedErrorsApi := &ErrorsApiMock{ +// GetErrorByIdFunc: func(ctx _context.Context, id string) ApiGetErrorByIdRequest { +// panic("mock out the GetErrorById method") +// }, +// GetErrorByIdExecuteFunc: func(r ApiGetErrorByIdRequest) (Error, *_nethttp.Response, error) { +// panic("mock out the GetErrorByIdExecute method") +// }, +// GetErrorsFunc: func(ctx _context.Context) ApiGetErrorsRequest { +// panic("mock out the GetErrors method") +// }, +// GetErrorsExecuteFunc: func(r ApiGetErrorsRequest) (ErrorList, *_nethttp.Response, error) { +// panic("mock out the GetErrorsExecute method") +// }, +// } +// +// // use mockedErrorsApi in code that requires ErrorsApi +// // and then make assertions. +// +// } +type ErrorsApiMock struct { + // GetErrorByIdFunc mocks the GetErrorById method. + GetErrorByIdFunc func(ctx _context.Context, id string) ApiGetErrorByIdRequest + + // GetErrorByIdExecuteFunc mocks the GetErrorByIdExecute method. + GetErrorByIdExecuteFunc func(r ApiGetErrorByIdRequest) (Error, *_nethttp.Response, error) + + // GetErrorsFunc mocks the GetErrors method. + GetErrorsFunc func(ctx _context.Context) ApiGetErrorsRequest + + // GetErrorsExecuteFunc mocks the GetErrorsExecute method. + GetErrorsExecuteFunc func(r ApiGetErrorsRequest) (ErrorList, *_nethttp.Response, error) + + // calls tracks calls to the methods. + calls struct { + // GetErrorById holds details about calls to the GetErrorById method. + GetErrorById []struct { + // Ctx is the ctx argument value. + Ctx _context.Context + // ID is the id argument value. + ID string + } + // GetErrorByIdExecute holds details about calls to the GetErrorByIdExecute method. + GetErrorByIdExecute []struct { + // R is the r argument value. + R ApiGetErrorByIdRequest + } + // GetErrors holds details about calls to the GetErrors method. + GetErrors []struct { + // Ctx is the ctx argument value. + Ctx _context.Context + } + // GetErrorsExecute holds details about calls to the GetErrorsExecute method. + GetErrorsExecute []struct { + // R is the r argument value. + R ApiGetErrorsRequest + } + } + lockGetErrorById sync.RWMutex + lockGetErrorByIdExecute sync.RWMutex + lockGetErrors sync.RWMutex + lockGetErrorsExecute sync.RWMutex +} + +// GetErrorById calls GetErrorByIdFunc. +func (mock *ErrorsApiMock) GetErrorById(ctx _context.Context, id string) ApiGetErrorByIdRequest { + if mock.GetErrorByIdFunc == nil { + panic("ErrorsApiMock.GetErrorByIdFunc: method is nil but ErrorsApi.GetErrorById was just called") + } + callInfo := struct { + Ctx _context.Context + ID string + }{ + Ctx: ctx, + ID: id, + } + mock.lockGetErrorById.Lock() + mock.calls.GetErrorById = append(mock.calls.GetErrorById, callInfo) + mock.lockGetErrorById.Unlock() + return mock.GetErrorByIdFunc(ctx, id) +} + +// GetErrorByIdCalls gets all the calls that were made to GetErrorById. +// Check the length with: +// len(mockedErrorsApi.GetErrorByIdCalls()) +func (mock *ErrorsApiMock) GetErrorByIdCalls() []struct { + Ctx _context.Context + ID string +} { + var calls []struct { + Ctx _context.Context + ID string + } + mock.lockGetErrorById.RLock() + calls = mock.calls.GetErrorById + mock.lockGetErrorById.RUnlock() + return calls +} + +// GetErrorByIdExecute calls GetErrorByIdExecuteFunc. +func (mock *ErrorsApiMock) GetErrorByIdExecute(r ApiGetErrorByIdRequest) (Error, *_nethttp.Response, error) { + if mock.GetErrorByIdExecuteFunc == nil { + panic("ErrorsApiMock.GetErrorByIdExecuteFunc: method is nil but ErrorsApi.GetErrorByIdExecute was just called") + } + callInfo := struct { + R ApiGetErrorByIdRequest + }{ + R: r, + } + mock.lockGetErrorByIdExecute.Lock() + mock.calls.GetErrorByIdExecute = append(mock.calls.GetErrorByIdExecute, callInfo) + mock.lockGetErrorByIdExecute.Unlock() + return mock.GetErrorByIdExecuteFunc(r) +} + +// GetErrorByIdExecuteCalls gets all the calls that were made to GetErrorByIdExecute. +// Check the length with: +// len(mockedErrorsApi.GetErrorByIdExecuteCalls()) +func (mock *ErrorsApiMock) GetErrorByIdExecuteCalls() []struct { + R ApiGetErrorByIdRequest +} { + var calls []struct { + R ApiGetErrorByIdRequest + } + mock.lockGetErrorByIdExecute.RLock() + calls = mock.calls.GetErrorByIdExecute + mock.lockGetErrorByIdExecute.RUnlock() + return calls +} + +// GetErrors calls GetErrorsFunc. +func (mock *ErrorsApiMock) GetErrors(ctx _context.Context) ApiGetErrorsRequest { + if mock.GetErrorsFunc == nil { + panic("ErrorsApiMock.GetErrorsFunc: method is nil but ErrorsApi.GetErrors was just called") + } + callInfo := struct { + Ctx _context.Context + }{ + Ctx: ctx, + } + mock.lockGetErrors.Lock() + mock.calls.GetErrors = append(mock.calls.GetErrors, callInfo) + mock.lockGetErrors.Unlock() + return mock.GetErrorsFunc(ctx) +} + +// GetErrorsCalls gets all the calls that were made to GetErrors. +// Check the length with: +// len(mockedErrorsApi.GetErrorsCalls()) +func (mock *ErrorsApiMock) GetErrorsCalls() []struct { + Ctx _context.Context +} { + var calls []struct { + Ctx _context.Context + } + mock.lockGetErrors.RLock() + calls = mock.calls.GetErrors + mock.lockGetErrors.RUnlock() + return calls +} + +// GetErrorsExecute calls GetErrorsExecuteFunc. +func (mock *ErrorsApiMock) GetErrorsExecute(r ApiGetErrorsRequest) (ErrorList, *_nethttp.Response, error) { + if mock.GetErrorsExecuteFunc == nil { + panic("ErrorsApiMock.GetErrorsExecuteFunc: method is nil but ErrorsApi.GetErrorsExecute was just called") + } + callInfo := struct { + R ApiGetErrorsRequest + }{ + R: r, + } + mock.lockGetErrorsExecute.Lock() + mock.calls.GetErrorsExecute = append(mock.calls.GetErrorsExecute, callInfo) + mock.lockGetErrorsExecute.Unlock() + return mock.GetErrorsExecuteFunc(r) +} + +// GetErrorsExecuteCalls gets all the calls that were made to GetErrorsExecute. +// Check the length with: +// len(mockedErrorsApi.GetErrorsExecuteCalls()) +func (mock *ErrorsApiMock) GetErrorsExecuteCalls() []struct { + R ApiGetErrorsRequest +} { + var calls []struct { + R ApiGetErrorsRequest + } + mock.lockGetErrorsExecute.RLock() + calls = mock.calls.GetErrorsExecute + mock.lockGetErrorsExecute.RUnlock() + return calls +} diff --git a/kafkamgmt/apiv1/client/model_cloud_region.go b/kafkamgmt/apiv1/client/model_cloud_region.go index 7d1156b3..c9843795 100644 --- a/kafkamgmt/apiv1/client/model_cloud_region.go +++ b/kafkamgmt/apiv1/client/model_cloud_region.go @@ -38,10 +38,9 @@ type CloudRegion struct { // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewCloudRegion(enabled bool, supportedInstanceTypes []string, capacity []RegionCapacityListItem) *CloudRegion { +func NewCloudRegion(enabled bool, capacity []RegionCapacityListItem) *CloudRegion { this := CloudRegion{} this.Enabled = enabled - this.SupportedInstanceTypes = supportedInstanceTypes this.Capacity = capacity return &this } diff --git a/kafkamgmt/apiv1/client/security_api_mock.go b/kafkamgmt/apiv1/client/security_api_mock.go new file mode 100644 index 00000000..e9e6ce67 --- /dev/null +++ b/kafkamgmt/apiv1/client/security_api_mock.go @@ -0,0 +1,566 @@ +// Code generated by moq; DO NOT EDIT. +// github.com/matryer/moq + +package kafkamgmtclient + +import ( + _context "context" + _nethttp "net/http" + "sync" +) + +// Ensure, that SecurityApiMock does implement SecurityApi. +// If this is not the case, regenerate this file with moq. +var _ SecurityApi = &SecurityApiMock{} + +// SecurityApiMock is a mock implementation of SecurityApi. +// +// func TestSomethingThatUsesSecurityApi(t *testing.T) { +// +// // make and configure a mocked SecurityApi +// mockedSecurityApi := &SecurityApiMock{ +// CreateServiceAccountFunc: func(ctx _context.Context) ApiCreateServiceAccountRequest { +// panic("mock out the CreateServiceAccount method") +// }, +// CreateServiceAccountExecuteFunc: func(r ApiCreateServiceAccountRequest) (ServiceAccount, *_nethttp.Response, error) { +// panic("mock out the CreateServiceAccountExecute method") +// }, +// DeleteServiceAccountByIdFunc: func(ctx _context.Context, id string) ApiDeleteServiceAccountByIdRequest { +// panic("mock out the DeleteServiceAccountById method") +// }, +// DeleteServiceAccountByIdExecuteFunc: func(r ApiDeleteServiceAccountByIdRequest) (Error, *_nethttp.Response, error) { +// panic("mock out the DeleteServiceAccountByIdExecute method") +// }, +// GetServiceAccountByIdFunc: func(ctx _context.Context, id string) ApiGetServiceAccountByIdRequest { +// panic("mock out the GetServiceAccountById method") +// }, +// GetServiceAccountByIdExecuteFunc: func(r ApiGetServiceAccountByIdRequest) (ServiceAccount, *_nethttp.Response, error) { +// panic("mock out the GetServiceAccountByIdExecute method") +// }, +// GetServiceAccountsFunc: func(ctx _context.Context) ApiGetServiceAccountsRequest { +// panic("mock out the GetServiceAccounts method") +// }, +// GetServiceAccountsExecuteFunc: func(r ApiGetServiceAccountsRequest) (ServiceAccountList, *_nethttp.Response, error) { +// panic("mock out the GetServiceAccountsExecute method") +// }, +// GetSsoProvidersFunc: func(ctx _context.Context) ApiGetSsoProvidersRequest { +// panic("mock out the GetSsoProviders method") +// }, +// GetSsoProvidersExecuteFunc: func(r ApiGetSsoProvidersRequest) (SsoProvider, *_nethttp.Response, error) { +// panic("mock out the GetSsoProvidersExecute method") +// }, +// ResetServiceAccountCredsFunc: func(ctx _context.Context, id string) ApiResetServiceAccountCredsRequest { +// panic("mock out the ResetServiceAccountCreds method") +// }, +// ResetServiceAccountCredsExecuteFunc: func(r ApiResetServiceAccountCredsRequest) (ServiceAccount, *_nethttp.Response, error) { +// panic("mock out the ResetServiceAccountCredsExecute method") +// }, +// } +// +// // use mockedSecurityApi in code that requires SecurityApi +// // and then make assertions. +// +// } +type SecurityApiMock struct { + // CreateServiceAccountFunc mocks the CreateServiceAccount method. + CreateServiceAccountFunc func(ctx _context.Context) ApiCreateServiceAccountRequest + + // CreateServiceAccountExecuteFunc mocks the CreateServiceAccountExecute method. + CreateServiceAccountExecuteFunc func(r ApiCreateServiceAccountRequest) (ServiceAccount, *_nethttp.Response, error) + + // DeleteServiceAccountByIdFunc mocks the DeleteServiceAccountById method. + DeleteServiceAccountByIdFunc func(ctx _context.Context, id string) ApiDeleteServiceAccountByIdRequest + + // DeleteServiceAccountByIdExecuteFunc mocks the DeleteServiceAccountByIdExecute method. + DeleteServiceAccountByIdExecuteFunc func(r ApiDeleteServiceAccountByIdRequest) (Error, *_nethttp.Response, error) + + // GetServiceAccountByIdFunc mocks the GetServiceAccountById method. + GetServiceAccountByIdFunc func(ctx _context.Context, id string) ApiGetServiceAccountByIdRequest + + // GetServiceAccountByIdExecuteFunc mocks the GetServiceAccountByIdExecute method. + GetServiceAccountByIdExecuteFunc func(r ApiGetServiceAccountByIdRequest) (ServiceAccount, *_nethttp.Response, error) + + // GetServiceAccountsFunc mocks the GetServiceAccounts method. + GetServiceAccountsFunc func(ctx _context.Context) ApiGetServiceAccountsRequest + + // GetServiceAccountsExecuteFunc mocks the GetServiceAccountsExecute method. + GetServiceAccountsExecuteFunc func(r ApiGetServiceAccountsRequest) (ServiceAccountList, *_nethttp.Response, error) + + // GetSsoProvidersFunc mocks the GetSsoProviders method. + GetSsoProvidersFunc func(ctx _context.Context) ApiGetSsoProvidersRequest + + // GetSsoProvidersExecuteFunc mocks the GetSsoProvidersExecute method. + GetSsoProvidersExecuteFunc func(r ApiGetSsoProvidersRequest) (SsoProvider, *_nethttp.Response, error) + + // ResetServiceAccountCredsFunc mocks the ResetServiceAccountCreds method. + ResetServiceAccountCredsFunc func(ctx _context.Context, id string) ApiResetServiceAccountCredsRequest + + // ResetServiceAccountCredsExecuteFunc mocks the ResetServiceAccountCredsExecute method. + ResetServiceAccountCredsExecuteFunc func(r ApiResetServiceAccountCredsRequest) (ServiceAccount, *_nethttp.Response, error) + + // calls tracks calls to the methods. + calls struct { + // CreateServiceAccount holds details about calls to the CreateServiceAccount method. + CreateServiceAccount []struct { + // Ctx is the ctx argument value. + Ctx _context.Context + } + // CreateServiceAccountExecute holds details about calls to the CreateServiceAccountExecute method. + CreateServiceAccountExecute []struct { + // R is the r argument value. + R ApiCreateServiceAccountRequest + } + // DeleteServiceAccountById holds details about calls to the DeleteServiceAccountById method. + DeleteServiceAccountById []struct { + // Ctx is the ctx argument value. + Ctx _context.Context + // ID is the id argument value. + ID string + } + // DeleteServiceAccountByIdExecute holds details about calls to the DeleteServiceAccountByIdExecute method. + DeleteServiceAccountByIdExecute []struct { + // R is the r argument value. + R ApiDeleteServiceAccountByIdRequest + } + // GetServiceAccountById holds details about calls to the GetServiceAccountById method. + GetServiceAccountById []struct { + // Ctx is the ctx argument value. + Ctx _context.Context + // ID is the id argument value. + ID string + } + // GetServiceAccountByIdExecute holds details about calls to the GetServiceAccountByIdExecute method. + GetServiceAccountByIdExecute []struct { + // R is the r argument value. + R ApiGetServiceAccountByIdRequest + } + // GetServiceAccounts holds details about calls to the GetServiceAccounts method. + GetServiceAccounts []struct { + // Ctx is the ctx argument value. + Ctx _context.Context + } + // GetServiceAccountsExecute holds details about calls to the GetServiceAccountsExecute method. + GetServiceAccountsExecute []struct { + // R is the r argument value. + R ApiGetServiceAccountsRequest + } + // GetSsoProviders holds details about calls to the GetSsoProviders method. + GetSsoProviders []struct { + // Ctx is the ctx argument value. + Ctx _context.Context + } + // GetSsoProvidersExecute holds details about calls to the GetSsoProvidersExecute method. + GetSsoProvidersExecute []struct { + // R is the r argument value. + R ApiGetSsoProvidersRequest + } + // ResetServiceAccountCreds holds details about calls to the ResetServiceAccountCreds method. + ResetServiceAccountCreds []struct { + // Ctx is the ctx argument value. + Ctx _context.Context + // ID is the id argument value. + ID string + } + // ResetServiceAccountCredsExecute holds details about calls to the ResetServiceAccountCredsExecute method. + ResetServiceAccountCredsExecute []struct { + // R is the r argument value. + R ApiResetServiceAccountCredsRequest + } + } + lockCreateServiceAccount sync.RWMutex + lockCreateServiceAccountExecute sync.RWMutex + lockDeleteServiceAccountById sync.RWMutex + lockDeleteServiceAccountByIdExecute sync.RWMutex + lockGetServiceAccountById sync.RWMutex + lockGetServiceAccountByIdExecute sync.RWMutex + lockGetServiceAccounts sync.RWMutex + lockGetServiceAccountsExecute sync.RWMutex + lockGetSsoProviders sync.RWMutex + lockGetSsoProvidersExecute sync.RWMutex + lockResetServiceAccountCreds sync.RWMutex + lockResetServiceAccountCredsExecute sync.RWMutex +} + +// CreateServiceAccount calls CreateServiceAccountFunc. +func (mock *SecurityApiMock) CreateServiceAccount(ctx _context.Context) ApiCreateServiceAccountRequest { + if mock.CreateServiceAccountFunc == nil { + panic("SecurityApiMock.CreateServiceAccountFunc: method is nil but SecurityApi.CreateServiceAccount was just called") + } + callInfo := struct { + Ctx _context.Context + }{ + Ctx: ctx, + } + mock.lockCreateServiceAccount.Lock() + mock.calls.CreateServiceAccount = append(mock.calls.CreateServiceAccount, callInfo) + mock.lockCreateServiceAccount.Unlock() + return mock.CreateServiceAccountFunc(ctx) +} + +// CreateServiceAccountCalls gets all the calls that were made to CreateServiceAccount. +// Check the length with: +// len(mockedSecurityApi.CreateServiceAccountCalls()) +func (mock *SecurityApiMock) CreateServiceAccountCalls() []struct { + Ctx _context.Context +} { + var calls []struct { + Ctx _context.Context + } + mock.lockCreateServiceAccount.RLock() + calls = mock.calls.CreateServiceAccount + mock.lockCreateServiceAccount.RUnlock() + return calls +} + +// CreateServiceAccountExecute calls CreateServiceAccountExecuteFunc. +func (mock *SecurityApiMock) CreateServiceAccountExecute(r ApiCreateServiceAccountRequest) (ServiceAccount, *_nethttp.Response, error) { + if mock.CreateServiceAccountExecuteFunc == nil { + panic("SecurityApiMock.CreateServiceAccountExecuteFunc: method is nil but SecurityApi.CreateServiceAccountExecute was just called") + } + callInfo := struct { + R ApiCreateServiceAccountRequest + }{ + R: r, + } + mock.lockCreateServiceAccountExecute.Lock() + mock.calls.CreateServiceAccountExecute = append(mock.calls.CreateServiceAccountExecute, callInfo) + mock.lockCreateServiceAccountExecute.Unlock() + return mock.CreateServiceAccountExecuteFunc(r) +} + +// CreateServiceAccountExecuteCalls gets all the calls that were made to CreateServiceAccountExecute. +// Check the length with: +// len(mockedSecurityApi.CreateServiceAccountExecuteCalls()) +func (mock *SecurityApiMock) CreateServiceAccountExecuteCalls() []struct { + R ApiCreateServiceAccountRequest +} { + var calls []struct { + R ApiCreateServiceAccountRequest + } + mock.lockCreateServiceAccountExecute.RLock() + calls = mock.calls.CreateServiceAccountExecute + mock.lockCreateServiceAccountExecute.RUnlock() + return calls +} + +// DeleteServiceAccountById calls DeleteServiceAccountByIdFunc. +func (mock *SecurityApiMock) DeleteServiceAccountById(ctx _context.Context, id string) ApiDeleteServiceAccountByIdRequest { + if mock.DeleteServiceAccountByIdFunc == nil { + panic("SecurityApiMock.DeleteServiceAccountByIdFunc: method is nil but SecurityApi.DeleteServiceAccountById was just called") + } + callInfo := struct { + Ctx _context.Context + ID string + }{ + Ctx: ctx, + ID: id, + } + mock.lockDeleteServiceAccountById.Lock() + mock.calls.DeleteServiceAccountById = append(mock.calls.DeleteServiceAccountById, callInfo) + mock.lockDeleteServiceAccountById.Unlock() + return mock.DeleteServiceAccountByIdFunc(ctx, id) +} + +// DeleteServiceAccountByIdCalls gets all the calls that were made to DeleteServiceAccountById. +// Check the length with: +// len(mockedSecurityApi.DeleteServiceAccountByIdCalls()) +func (mock *SecurityApiMock) DeleteServiceAccountByIdCalls() []struct { + Ctx _context.Context + ID string +} { + var calls []struct { + Ctx _context.Context + ID string + } + mock.lockDeleteServiceAccountById.RLock() + calls = mock.calls.DeleteServiceAccountById + mock.lockDeleteServiceAccountById.RUnlock() + return calls +} + +// DeleteServiceAccountByIdExecute calls DeleteServiceAccountByIdExecuteFunc. +func (mock *SecurityApiMock) DeleteServiceAccountByIdExecute(r ApiDeleteServiceAccountByIdRequest) (Error, *_nethttp.Response, error) { + if mock.DeleteServiceAccountByIdExecuteFunc == nil { + panic("SecurityApiMock.DeleteServiceAccountByIdExecuteFunc: method is nil but SecurityApi.DeleteServiceAccountByIdExecute was just called") + } + callInfo := struct { + R ApiDeleteServiceAccountByIdRequest + }{ + R: r, + } + mock.lockDeleteServiceAccountByIdExecute.Lock() + mock.calls.DeleteServiceAccountByIdExecute = append(mock.calls.DeleteServiceAccountByIdExecute, callInfo) + mock.lockDeleteServiceAccountByIdExecute.Unlock() + return mock.DeleteServiceAccountByIdExecuteFunc(r) +} + +// DeleteServiceAccountByIdExecuteCalls gets all the calls that were made to DeleteServiceAccountByIdExecute. +// Check the length with: +// len(mockedSecurityApi.DeleteServiceAccountByIdExecuteCalls()) +func (mock *SecurityApiMock) DeleteServiceAccountByIdExecuteCalls() []struct { + R ApiDeleteServiceAccountByIdRequest +} { + var calls []struct { + R ApiDeleteServiceAccountByIdRequest + } + mock.lockDeleteServiceAccountByIdExecute.RLock() + calls = mock.calls.DeleteServiceAccountByIdExecute + mock.lockDeleteServiceAccountByIdExecute.RUnlock() + return calls +} + +// GetServiceAccountById calls GetServiceAccountByIdFunc. +func (mock *SecurityApiMock) GetServiceAccountById(ctx _context.Context, id string) ApiGetServiceAccountByIdRequest { + if mock.GetServiceAccountByIdFunc == nil { + panic("SecurityApiMock.GetServiceAccountByIdFunc: method is nil but SecurityApi.GetServiceAccountById was just called") + } + callInfo := struct { + Ctx _context.Context + ID string + }{ + Ctx: ctx, + ID: id, + } + mock.lockGetServiceAccountById.Lock() + mock.calls.GetServiceAccountById = append(mock.calls.GetServiceAccountById, callInfo) + mock.lockGetServiceAccountById.Unlock() + return mock.GetServiceAccountByIdFunc(ctx, id) +} + +// GetServiceAccountByIdCalls gets all the calls that were made to GetServiceAccountById. +// Check the length with: +// len(mockedSecurityApi.GetServiceAccountByIdCalls()) +func (mock *SecurityApiMock) GetServiceAccountByIdCalls() []struct { + Ctx _context.Context + ID string +} { + var calls []struct { + Ctx _context.Context + ID string + } + mock.lockGetServiceAccountById.RLock() + calls = mock.calls.GetServiceAccountById + mock.lockGetServiceAccountById.RUnlock() + return calls +} + +// GetServiceAccountByIdExecute calls GetServiceAccountByIdExecuteFunc. +func (mock *SecurityApiMock) GetServiceAccountByIdExecute(r ApiGetServiceAccountByIdRequest) (ServiceAccount, *_nethttp.Response, error) { + if mock.GetServiceAccountByIdExecuteFunc == nil { + panic("SecurityApiMock.GetServiceAccountByIdExecuteFunc: method is nil but SecurityApi.GetServiceAccountByIdExecute was just called") + } + callInfo := struct { + R ApiGetServiceAccountByIdRequest + }{ + R: r, + } + mock.lockGetServiceAccountByIdExecute.Lock() + mock.calls.GetServiceAccountByIdExecute = append(mock.calls.GetServiceAccountByIdExecute, callInfo) + mock.lockGetServiceAccountByIdExecute.Unlock() + return mock.GetServiceAccountByIdExecuteFunc(r) +} + +// GetServiceAccountByIdExecuteCalls gets all the calls that were made to GetServiceAccountByIdExecute. +// Check the length with: +// len(mockedSecurityApi.GetServiceAccountByIdExecuteCalls()) +func (mock *SecurityApiMock) GetServiceAccountByIdExecuteCalls() []struct { + R ApiGetServiceAccountByIdRequest +} { + var calls []struct { + R ApiGetServiceAccountByIdRequest + } + mock.lockGetServiceAccountByIdExecute.RLock() + calls = mock.calls.GetServiceAccountByIdExecute + mock.lockGetServiceAccountByIdExecute.RUnlock() + return calls +} + +// GetServiceAccounts calls GetServiceAccountsFunc. +func (mock *SecurityApiMock) GetServiceAccounts(ctx _context.Context) ApiGetServiceAccountsRequest { + if mock.GetServiceAccountsFunc == nil { + panic("SecurityApiMock.GetServiceAccountsFunc: method is nil but SecurityApi.GetServiceAccounts was just called") + } + callInfo := struct { + Ctx _context.Context + }{ + Ctx: ctx, + } + mock.lockGetServiceAccounts.Lock() + mock.calls.GetServiceAccounts = append(mock.calls.GetServiceAccounts, callInfo) + mock.lockGetServiceAccounts.Unlock() + return mock.GetServiceAccountsFunc(ctx) +} + +// GetServiceAccountsCalls gets all the calls that were made to GetServiceAccounts. +// Check the length with: +// len(mockedSecurityApi.GetServiceAccountsCalls()) +func (mock *SecurityApiMock) GetServiceAccountsCalls() []struct { + Ctx _context.Context +} { + var calls []struct { + Ctx _context.Context + } + mock.lockGetServiceAccounts.RLock() + calls = mock.calls.GetServiceAccounts + mock.lockGetServiceAccounts.RUnlock() + return calls +} + +// GetServiceAccountsExecute calls GetServiceAccountsExecuteFunc. +func (mock *SecurityApiMock) GetServiceAccountsExecute(r ApiGetServiceAccountsRequest) (ServiceAccountList, *_nethttp.Response, error) { + if mock.GetServiceAccountsExecuteFunc == nil { + panic("SecurityApiMock.GetServiceAccountsExecuteFunc: method is nil but SecurityApi.GetServiceAccountsExecute was just called") + } + callInfo := struct { + R ApiGetServiceAccountsRequest + }{ + R: r, + } + mock.lockGetServiceAccountsExecute.Lock() + mock.calls.GetServiceAccountsExecute = append(mock.calls.GetServiceAccountsExecute, callInfo) + mock.lockGetServiceAccountsExecute.Unlock() + return mock.GetServiceAccountsExecuteFunc(r) +} + +// GetServiceAccountsExecuteCalls gets all the calls that were made to GetServiceAccountsExecute. +// Check the length with: +// len(mockedSecurityApi.GetServiceAccountsExecuteCalls()) +func (mock *SecurityApiMock) GetServiceAccountsExecuteCalls() []struct { + R ApiGetServiceAccountsRequest +} { + var calls []struct { + R ApiGetServiceAccountsRequest + } + mock.lockGetServiceAccountsExecute.RLock() + calls = mock.calls.GetServiceAccountsExecute + mock.lockGetServiceAccountsExecute.RUnlock() + return calls +} + +// GetSsoProviders calls GetSsoProvidersFunc. +func (mock *SecurityApiMock) GetSsoProviders(ctx _context.Context) ApiGetSsoProvidersRequest { + if mock.GetSsoProvidersFunc == nil { + panic("SecurityApiMock.GetSsoProvidersFunc: method is nil but SecurityApi.GetSsoProviders was just called") + } + callInfo := struct { + Ctx _context.Context + }{ + Ctx: ctx, + } + mock.lockGetSsoProviders.Lock() + mock.calls.GetSsoProviders = append(mock.calls.GetSsoProviders, callInfo) + mock.lockGetSsoProviders.Unlock() + return mock.GetSsoProvidersFunc(ctx) +} + +// GetSsoProvidersCalls gets all the calls that were made to GetSsoProviders. +// Check the length with: +// len(mockedSecurityApi.GetSsoProvidersCalls()) +func (mock *SecurityApiMock) GetSsoProvidersCalls() []struct { + Ctx _context.Context +} { + var calls []struct { + Ctx _context.Context + } + mock.lockGetSsoProviders.RLock() + calls = mock.calls.GetSsoProviders + mock.lockGetSsoProviders.RUnlock() + return calls +} + +// GetSsoProvidersExecute calls GetSsoProvidersExecuteFunc. +func (mock *SecurityApiMock) GetSsoProvidersExecute(r ApiGetSsoProvidersRequest) (SsoProvider, *_nethttp.Response, error) { + if mock.GetSsoProvidersExecuteFunc == nil { + panic("SecurityApiMock.GetSsoProvidersExecuteFunc: method is nil but SecurityApi.GetSsoProvidersExecute was just called") + } + callInfo := struct { + R ApiGetSsoProvidersRequest + }{ + R: r, + } + mock.lockGetSsoProvidersExecute.Lock() + mock.calls.GetSsoProvidersExecute = append(mock.calls.GetSsoProvidersExecute, callInfo) + mock.lockGetSsoProvidersExecute.Unlock() + return mock.GetSsoProvidersExecuteFunc(r) +} + +// GetSsoProvidersExecuteCalls gets all the calls that were made to GetSsoProvidersExecute. +// Check the length with: +// len(mockedSecurityApi.GetSsoProvidersExecuteCalls()) +func (mock *SecurityApiMock) GetSsoProvidersExecuteCalls() []struct { + R ApiGetSsoProvidersRequest +} { + var calls []struct { + R ApiGetSsoProvidersRequest + } + mock.lockGetSsoProvidersExecute.RLock() + calls = mock.calls.GetSsoProvidersExecute + mock.lockGetSsoProvidersExecute.RUnlock() + return calls +} + +// ResetServiceAccountCreds calls ResetServiceAccountCredsFunc. +func (mock *SecurityApiMock) ResetServiceAccountCreds(ctx _context.Context, id string) ApiResetServiceAccountCredsRequest { + if mock.ResetServiceAccountCredsFunc == nil { + panic("SecurityApiMock.ResetServiceAccountCredsFunc: method is nil but SecurityApi.ResetServiceAccountCreds was just called") + } + callInfo := struct { + Ctx _context.Context + ID string + }{ + Ctx: ctx, + ID: id, + } + mock.lockResetServiceAccountCreds.Lock() + mock.calls.ResetServiceAccountCreds = append(mock.calls.ResetServiceAccountCreds, callInfo) + mock.lockResetServiceAccountCreds.Unlock() + return mock.ResetServiceAccountCredsFunc(ctx, id) +} + +// ResetServiceAccountCredsCalls gets all the calls that were made to ResetServiceAccountCreds. +// Check the length with: +// len(mockedSecurityApi.ResetServiceAccountCredsCalls()) +func (mock *SecurityApiMock) ResetServiceAccountCredsCalls() []struct { + Ctx _context.Context + ID string +} { + var calls []struct { + Ctx _context.Context + ID string + } + mock.lockResetServiceAccountCreds.RLock() + calls = mock.calls.ResetServiceAccountCreds + mock.lockResetServiceAccountCreds.RUnlock() + return calls +} + +// ResetServiceAccountCredsExecute calls ResetServiceAccountCredsExecuteFunc. +func (mock *SecurityApiMock) ResetServiceAccountCredsExecute(r ApiResetServiceAccountCredsRequest) (ServiceAccount, *_nethttp.Response, error) { + if mock.ResetServiceAccountCredsExecuteFunc == nil { + panic("SecurityApiMock.ResetServiceAccountCredsExecuteFunc: method is nil but SecurityApi.ResetServiceAccountCredsExecute was just called") + } + callInfo := struct { + R ApiResetServiceAccountCredsRequest + }{ + R: r, + } + mock.lockResetServiceAccountCredsExecute.Lock() + mock.calls.ResetServiceAccountCredsExecute = append(mock.calls.ResetServiceAccountCredsExecute, callInfo) + mock.lockResetServiceAccountCredsExecute.Unlock() + return mock.ResetServiceAccountCredsExecuteFunc(r) +} + +// ResetServiceAccountCredsExecuteCalls gets all the calls that were made to ResetServiceAccountCredsExecute. +// Check the length with: +// len(mockedSecurityApi.ResetServiceAccountCredsExecuteCalls()) +func (mock *SecurityApiMock) ResetServiceAccountCredsExecuteCalls() []struct { + R ApiResetServiceAccountCredsRequest +} { + var calls []struct { + R ApiResetServiceAccountCredsRequest + } + mock.lockResetServiceAccountCredsExecute.RLock() + calls = mock.calls.ResetServiceAccountCredsExecute + mock.lockResetServiceAccountCredsExecute.RUnlock() + return calls +}