Documentation ¶
Overview ¶
Package mock_argocdClient is a generated GoMock package.
Package argocd is a generated GoMock package.
Package argocd is a generated GoMock package.
Index ¶
- Constants
- type ArgocdClient
- type AuthOperation
- type Client
- type ClusterData
- type ClusterDataConfig
- type ClusterInstance
- type ClusterOperation
- type ClusterResponse
- type CodeRepoResponse
- type CoderepoOperation
- type ConnectionState
- type ErrorNotFound
- type Info
- type IsNoAuth
- type MockAuthOperation
- type MockAuthOperationMockRecorder
- type MockClusterOperation
- func (m *MockClusterOperation) CreateCluster(clusterInstance *ClusterInstance) error
- func (m *MockClusterOperation) DeleteCluster(clusterURL string) (string, error)
- func (m *MockClusterOperation) EXPECT() *MockClusterOperationMockRecorder
- func (m *MockClusterOperation) GetCluster(clusterURL string) (*ClusterData, error)
- func (m *MockClusterOperation) GetClusterInfo(clusterURL string) (*ClusterResponse, error)
- func (m *MockClusterOperation) UpdateCluster(clusterInstance *ClusterInstance) error
- type MockClusterOperationMockRecorder
- func (mr *MockClusterOperationMockRecorder) CreateCluster(clusterInstance interface{}) *gomock.Call
- func (mr *MockClusterOperationMockRecorder) DeleteCluster(clusterURL interface{}) *gomock.Call
- func (mr *MockClusterOperationMockRecorder) GetCluster(clusterURL interface{}) *gomock.Call
- func (mr *MockClusterOperationMockRecorder) GetClusterInfo(clusterURL interface{}) *gomock.Call
- func (mr *MockClusterOperationMockRecorder) UpdateCluster(clusterInstance interface{}) *gomock.Call
- type MockCoderepoOperation
- func (m *MockCoderepoOperation) CreateRepository(repoName, key, repourl string) error
- func (m *MockCoderepoOperation) DeleteRepository(repoURL string) error
- func (m *MockCoderepoOperation) EXPECT() *MockCoderepoOperationMockRecorder
- func (m *MockCoderepoOperation) GetRepositoryInfo(repoURL string) (*CodeRepoResponse, error)
- func (m *MockCoderepoOperation) UpdateRepository(repoName, key, repourl string) error
- type MockCoderepoOperationMockRecorder
- func (mr *MockCoderepoOperationMockRecorder) CreateRepository(repoName, key, repourl interface{}) *gomock.Call
- func (mr *MockCoderepoOperationMockRecorder) DeleteRepository(repoURL interface{}) *gomock.Call
- func (mr *MockCoderepoOperationMockRecorder) GetRepositoryInfo(repoURL interface{}) *gomock.Call
- func (mr *MockCoderepoOperationMockRecorder) UpdateRepository(repoName, key, repourl interface{}) *gomock.Call
- type RepositoryData
Constants ¶
const ( AdminInitialAdminSecret = "argocd-initial-admin-secret" DefaultNamespace = "argocd" DefaultServiceAccount = "default" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArgocdClient ¶
type ArgocdClient struct { ArgocdAuth AuthOperation ArgocdCluster ClusterOperation ArgocdCodeRepo CoderepoOperation // contains filtered or unexported fields }
func NewArgocd ¶
func NewArgocd(url string) (c *ArgocdClient)
func (*ArgocdClient) Auth ¶
func (c *ArgocdClient) Auth() AuthOperation
func (*ArgocdClient) Cluster ¶
func (c *ArgocdClient) Cluster() ClusterOperation
func (*ArgocdClient) CodeRepo ¶
func (c *ArgocdClient) CodeRepo() CoderepoOperation
type AuthOperation ¶
func NewArgocdAuth ¶
func NewArgocdAuth(c *ArgocdClient) AuthOperation
type ClusterData ¶
type ClusterDataConfig ¶
type ClusterDataConfig struct {
TlsClientConfig tlsClientConfig `json:"tlsClientConfig"`
}
type ClusterInstance ¶
type ClusterInstance struct { Name string `json:"name"` ApiServer string `json:"apiServer"` ClusterType string `json:"clusterType"` HostCluster string `json:"hostType"` Provider string `json:"provider"` CertificateData string `json:"certficateData"` CaData string `json:"caData"` KeyData string `json:"keyData"` Usage resourcev1alpha1.ClusterUsage `json:"usage"` }
type ClusterOperation ¶
type ClusterOperation interface { GetClusterInfo(clusterURL string) (*ClusterResponse, error) GetCluster(clusterURL string) (*ClusterData, error) CreateCluster(clusterInstance *ClusterInstance) error DeleteCluster(clusterURL string) (string, error) UpdateCluster(clusterInstance *ClusterInstance) error }
func NewArgocdCluster ¶
func NewArgocdCluster(argocd *ArgocdClient) ClusterOperation
type ClusterResponse ¶
type ClusterResponse struct { Name string `json:"name"` ConnectionState ConnectionState `json:"connectionState"` Server string `json:"server"` }
type CodeRepoResponse ¶
type CodeRepoResponse struct { Name string `json:"name"` ConnectionState ConnectionState `json:"connectionState"` Repo string `json:"repo"` }
type CoderepoOperation ¶
type CoderepoOperation interface { CreateRepository(repoName, key, repourl string) error UpdateRepository(repoName, key, repourl string) error GetRepositoryInfo(repoURL string) (*CodeRepoResponse, error) DeleteRepository(repoURL string) error }
func NewArgocdCodeRepo ¶
func NewArgocdCodeRepo(argocd *ArgocdClient) CoderepoOperation
type ConnectionState ¶
type ErrorNotFound ¶
func (*ErrorNotFound) Error ¶
func (e *ErrorNotFound) Error() string
type MockAuthOperation ¶
type MockAuthOperation struct {
// contains filtered or unexported fields
}
MockAuthOperation is a mock of AuthOperation interface.
func NewMockAuthOperation ¶
func NewMockAuthOperation(ctrl *gomock.Controller) *MockAuthOperation
NewMockAuthOperation creates a new mock instance.
func (*MockAuthOperation) EXPECT ¶
func (m *MockAuthOperation) EXPECT() *MockAuthOperationMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockAuthOperation) GetPassword ¶
func (m *MockAuthOperation) GetPassword() (string, error)
GetPassword mocks base method.
func (*MockAuthOperation) Login ¶
func (m *MockAuthOperation) Login() error
Login mocks base method.
type MockAuthOperationMockRecorder ¶
type MockAuthOperationMockRecorder struct {
// contains filtered or unexported fields
}
MockAuthOperationMockRecorder is the mock recorder for MockAuthOperation.
func (*MockAuthOperationMockRecorder) GetPassword ¶
func (mr *MockAuthOperationMockRecorder) GetPassword() *gomock.Call
GetPassword indicates an expected call of GetPassword.
func (*MockAuthOperationMockRecorder) Login ¶
func (mr *MockAuthOperationMockRecorder) Login() *gomock.Call
Login indicates an expected call of Login.
type MockClusterOperation ¶
type MockClusterOperation struct {
// contains filtered or unexported fields
}
MockClusterOperation is a mock of ClusterOperation interface.
func NewMockClusterOperation ¶
func NewMockClusterOperation(ctrl *gomock.Controller) *MockClusterOperation
NewMockClusterOperation creates a new mock instance.
func (*MockClusterOperation) CreateCluster ¶
func (m *MockClusterOperation) CreateCluster(clusterInstance *ClusterInstance) error
CreateCluster mocks base method.
func (*MockClusterOperation) DeleteCluster ¶
func (m *MockClusterOperation) DeleteCluster(clusterURL string) (string, error)
DeleteCluster mocks base method.
func (*MockClusterOperation) EXPECT ¶
func (m *MockClusterOperation) EXPECT() *MockClusterOperationMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockClusterOperation) GetCluster ¶
func (m *MockClusterOperation) GetCluster(clusterURL string) (*ClusterData, error)
GetCluster mocks base method.
func (*MockClusterOperation) GetClusterInfo ¶
func (m *MockClusterOperation) GetClusterInfo(clusterURL string) (*ClusterResponse, error)
GetClusterInfo mocks base method.
func (*MockClusterOperation) UpdateCluster ¶
func (m *MockClusterOperation) UpdateCluster(clusterInstance *ClusterInstance) error
UpdateCluster mocks base method.
type MockClusterOperationMockRecorder ¶
type MockClusterOperationMockRecorder struct {
// contains filtered or unexported fields
}
MockClusterOperationMockRecorder is the mock recorder for MockClusterOperation.
func (*MockClusterOperationMockRecorder) CreateCluster ¶
func (mr *MockClusterOperationMockRecorder) CreateCluster(clusterInstance interface{}) *gomock.Call
CreateCluster indicates an expected call of CreateCluster.
func (*MockClusterOperationMockRecorder) DeleteCluster ¶
func (mr *MockClusterOperationMockRecorder) DeleteCluster(clusterURL interface{}) *gomock.Call
DeleteCluster indicates an expected call of DeleteCluster.
func (*MockClusterOperationMockRecorder) GetCluster ¶
func (mr *MockClusterOperationMockRecorder) GetCluster(clusterURL interface{}) *gomock.Call
GetCluster indicates an expected call of GetCluster.
func (*MockClusterOperationMockRecorder) GetClusterInfo ¶
func (mr *MockClusterOperationMockRecorder) GetClusterInfo(clusterURL interface{}) *gomock.Call
GetClusterInfo indicates an expected call of GetClusterInfo.
func (*MockClusterOperationMockRecorder) UpdateCluster ¶
func (mr *MockClusterOperationMockRecorder) UpdateCluster(clusterInstance interface{}) *gomock.Call
UpdateCluster indicates an expected call of UpdateCluster.
type MockCoderepoOperation ¶
type MockCoderepoOperation struct {
// contains filtered or unexported fields
}
MockCoderepoOperation is a mock of CoderepoOperation interface.
func NewMockCoderepoOperation ¶
func NewMockCoderepoOperation(ctrl *gomock.Controller) *MockCoderepoOperation
NewMockCoderepoOperation creates a new mock instance.
func (*MockCoderepoOperation) CreateRepository ¶
func (m *MockCoderepoOperation) CreateRepository(repoName, key, repourl string) error
CreateRepository mocks base method.
func (*MockCoderepoOperation) DeleteRepository ¶
func (m *MockCoderepoOperation) DeleteRepository(repoURL string) error
DeleteRepository mocks base method.
func (*MockCoderepoOperation) EXPECT ¶
func (m *MockCoderepoOperation) EXPECT() *MockCoderepoOperationMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockCoderepoOperation) GetRepositoryInfo ¶
func (m *MockCoderepoOperation) GetRepositoryInfo(repoURL string) (*CodeRepoResponse, error)
GetRepositoryInfo mocks base method.
func (*MockCoderepoOperation) UpdateRepository ¶
func (m *MockCoderepoOperation) UpdateRepository(repoName, key, repourl string) error
UpdateRepository mocks base method.
type MockCoderepoOperationMockRecorder ¶
type MockCoderepoOperationMockRecorder struct {
// contains filtered or unexported fields
}
MockCoderepoOperationMockRecorder is the mock recorder for MockCoderepoOperation.
func (*MockCoderepoOperationMockRecorder) CreateRepository ¶
func (mr *MockCoderepoOperationMockRecorder) CreateRepository(repoName, key, repourl interface{}) *gomock.Call
CreateRepository indicates an expected call of CreateRepository.
func (*MockCoderepoOperationMockRecorder) DeleteRepository ¶
func (mr *MockCoderepoOperationMockRecorder) DeleteRepository(repoURL interface{}) *gomock.Call
DeleteRepository indicates an expected call of DeleteRepository.
func (*MockCoderepoOperationMockRecorder) GetRepositoryInfo ¶
func (mr *MockCoderepoOperationMockRecorder) GetRepositoryInfo(repoURL interface{}) *gomock.Call
GetRepositoryInfo indicates an expected call of GetRepositoryInfo.
func (*MockCoderepoOperationMockRecorder) UpdateRepository ¶
func (mr *MockCoderepoOperationMockRecorder) UpdateRepository(repoName, key, repourl interface{}) *gomock.Call
UpdateRepository indicates an expected call of UpdateRepository.