Documentation
¶
Index ¶
- type ConfigFileCommand
- type ConfigFileCommandInterface
- type ContextCommand
- type ContextCommandInterface
- type KubeClusterCommand
- type KubeClusterCommandInterface
- type KubernetesCommand
- type KubernetesCommandInterface
- type MockConfigFileCommandInterface
- func (_m *MockConfigFileCommandInterface[T]) ConfigureFlags(cmd *cobra.Command)
- func (_m *MockConfigFileCommandInterface[T]) EXPECT() *MockConfigFileCommandInterface_Expecter[T]
- func (_m *MockConfigFileCommandInterface[T]) GenerateConfigSchema() ([]byte, error)
- func (_m *MockConfigFileCommandInterface[T]) ReadConfigFile(ctx context.Context) (T, error)
- type MockConfigFileCommandInterface_ConfigureFlags_Call
- func (_c *MockConfigFileCommandInterface_ConfigureFlags_Call[T]) Return() *MockConfigFileCommandInterface_ConfigureFlags_Call[T]
- func (_c *MockConfigFileCommandInterface_ConfigureFlags_Call[T]) Run(run func(cmd *cobra.Command)) *MockConfigFileCommandInterface_ConfigureFlags_Call[T]
- func (_c *MockConfigFileCommandInterface_ConfigureFlags_Call[T]) RunAndReturn(run func(*cobra.Command)) *MockConfigFileCommandInterface_ConfigureFlags_Call[T]
- type MockConfigFileCommandInterface_Expecter
- func (_e *MockConfigFileCommandInterface_Expecter[T]) ConfigureFlags(cmd interface{}) *MockConfigFileCommandInterface_ConfigureFlags_Call[T]
- func (_e *MockConfigFileCommandInterface_Expecter[T]) GenerateConfigSchema() *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]
- func (_e *MockConfigFileCommandInterface_Expecter[T]) ReadConfigFile(ctx interface{}) *MockConfigFileCommandInterface_ReadConfigFile_Call[T]
- type MockConfigFileCommandInterface_GenerateConfigSchema_Call
- func (_c *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]) Return(_a0 []byte, _a1 error) *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]
- func (_c *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]) Run(run func()) *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]
- func (_c *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]) RunAndReturn(run func() ([]byte, error)) *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]
- type MockConfigFileCommandInterface_ReadConfigFile_Call
- func (_c *MockConfigFileCommandInterface_ReadConfigFile_Call[T]) Return(_a0 T, _a1 error) *MockConfigFileCommandInterface_ReadConfigFile_Call[T]
- func (_c *MockConfigFileCommandInterface_ReadConfigFile_Call[T]) Run(run func(ctx context.Context)) *MockConfigFileCommandInterface_ReadConfigFile_Call[T]
- func (_c *MockConfigFileCommandInterface_ReadConfigFile_Call[T]) RunAndReturn(run func(context.Context) (T, error)) *MockConfigFileCommandInterface_ReadConfigFile_Call[T]
- type MockContextCommandInterface
- type MockContextCommandInterface_ConfigureFlags_Call
- func (_c *MockContextCommandInterface_ConfigureFlags_Call) Return() *MockContextCommandInterface_ConfigureFlags_Call
- func (_c *MockContextCommandInterface_ConfigureFlags_Call) Run(run func(cmd *cobra.Command)) *MockContextCommandInterface_ConfigureFlags_Call
- func (_c *MockContextCommandInterface_ConfigureFlags_Call) RunAndReturn(run func(*cobra.Command)) *MockContextCommandInterface_ConfigureFlags_Call
- type MockContextCommandInterface_Expecter
- type MockContextCommandInterface_GetCommandContext_Call
- func (_c *MockContextCommandInterface_GetCommandContext_Call) Return(_a0 *contexts.Context, _a1 context.CancelFunc) *MockContextCommandInterface_GetCommandContext_Call
- func (_c *MockContextCommandInterface_GetCommandContext_Call) Run(run func()) *MockContextCommandInterface_GetCommandContext_Call
- func (_c *MockContextCommandInterface_GetCommandContext_Call) RunAndReturn(run func() (*contexts.Context, context.CancelFunc)) *MockContextCommandInterface_GetCommandContext_Call
- type MockKubeClusterCommandInterface
- func (_m *MockKubeClusterCommandInterface) ConfigureFlags(cmd *cobra.Command)
- func (_m *MockKubeClusterCommandInterface) EXPECT() *MockKubeClusterCommandInterface_Expecter
- func (_m *MockKubeClusterCommandInterface) GetClusterConfig() (*rest.Config, error)
- func (_m *MockKubeClusterCommandInterface) NewKubeClusterClient() (kubecluster.ClientInterface, error)
- type MockKubeClusterCommandInterface_ConfigureFlags_Call
- func (_c *MockKubeClusterCommandInterface_ConfigureFlags_Call) Return() *MockKubeClusterCommandInterface_ConfigureFlags_Call
- func (_c *MockKubeClusterCommandInterface_ConfigureFlags_Call) Run(run func(cmd *cobra.Command)) *MockKubeClusterCommandInterface_ConfigureFlags_Call
- func (_c *MockKubeClusterCommandInterface_ConfigureFlags_Call) RunAndReturn(run func(*cobra.Command)) *MockKubeClusterCommandInterface_ConfigureFlags_Call
- type MockKubeClusterCommandInterface_Expecter
- func (_e *MockKubeClusterCommandInterface_Expecter) ConfigureFlags(cmd interface{}) *MockKubeClusterCommandInterface_ConfigureFlags_Call
- func (_e *MockKubeClusterCommandInterface_Expecter) GetClusterConfig() *MockKubeClusterCommandInterface_GetClusterConfig_Call
- func (_e *MockKubeClusterCommandInterface_Expecter) NewKubeClusterClient() *MockKubeClusterCommandInterface_NewKubeClusterClient_Call
- type MockKubeClusterCommandInterface_GetClusterConfig_Call
- func (_c *MockKubeClusterCommandInterface_GetClusterConfig_Call) Return(_a0 *rest.Config, _a1 error) *MockKubeClusterCommandInterface_GetClusterConfig_Call
- func (_c *MockKubeClusterCommandInterface_GetClusterConfig_Call) Run(run func()) *MockKubeClusterCommandInterface_GetClusterConfig_Call
- func (_c *MockKubeClusterCommandInterface_GetClusterConfig_Call) RunAndReturn(run func() (*rest.Config, error)) *MockKubeClusterCommandInterface_GetClusterConfig_Call
- type MockKubeClusterCommandInterface_NewKubeClusterClient_Call
- func (_c *MockKubeClusterCommandInterface_NewKubeClusterClient_Call) Return(_a0 kubecluster.ClientInterface, _a1 error) *MockKubeClusterCommandInterface_NewKubeClusterClient_Call
- func (_c *MockKubeClusterCommandInterface_NewKubeClusterClient_Call) Run(run func()) *MockKubeClusterCommandInterface_NewKubeClusterClient_Call
- func (_c *MockKubeClusterCommandInterface_NewKubeClusterClient_Call) RunAndReturn(run func() (kubecluster.ClientInterface, error)) *MockKubeClusterCommandInterface_NewKubeClusterClient_Call
- type MockKubernetesCommandInterface
- type MockKubernetesCommandInterface_ConfigureFlags_Call
- func (_c *MockKubernetesCommandInterface_ConfigureFlags_Call) Return() *MockKubernetesCommandInterface_ConfigureFlags_Call
- func (_c *MockKubernetesCommandInterface_ConfigureFlags_Call) Run(run func(cmd *cobra.Command)) *MockKubernetesCommandInterface_ConfigureFlags_Call
- func (_c *MockKubernetesCommandInterface_ConfigureFlags_Call) RunAndReturn(run func(*cobra.Command)) *MockKubernetesCommandInterface_ConfigureFlags_Call
- type MockKubernetesCommandInterface_Expecter
- type MockKubernetesCommandInterface_GetClusterConfig_Call
- func (_c *MockKubernetesCommandInterface_GetClusterConfig_Call) Return(_a0 *rest.Config, _a1 error) *MockKubernetesCommandInterface_GetClusterConfig_Call
- func (_c *MockKubernetesCommandInterface_GetClusterConfig_Call) Run(run func()) *MockKubernetesCommandInterface_GetClusterConfig_Call
- func (_c *MockKubernetesCommandInterface_GetClusterConfig_Call) RunAndReturn(run func() (*rest.Config, error)) *MockKubernetesCommandInterface_GetClusterConfig_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConfigFileCommand ¶
type ConfigFileCommand[T interface{}] struct {
ConfigFilePath string
}
Gets a config file path from the command line and reads the config file into a struct of type T. The flag is required. The struct is then validated using the "jsonschema" and "validate" tags.
func NewConfigFileCommand ¶ added in v0.0.2
func NewConfigFileCommand[T interface{}]() *ConfigFileCommand[T]
func (*ConfigFileCommand[T]) ConfigureFlags ¶
func (cfc *ConfigFileCommand[T]) ConfigureFlags(cmd *cobra.Command)
func (*ConfigFileCommand[T]) GenerateConfigSchema ¶
func (cfc *ConfigFileCommand[T]) GenerateConfigSchema() ([]byte, error)
func (*ConfigFileCommand[T]) ReadConfigFile ¶
func (cfc *ConfigFileCommand[T]) ReadConfigFile(ctx context.Context) (T, error)
Read a configuration file provided via CLI flag, validate it, and return the loaded configuration.
type ConfigFileCommandInterface ¶ added in v0.0.2
type ContextCommand ¶
type ContextCommand struct {
Timeout time.Duration
// If false, the command will not have a timeout, and will not have a timeout flag.
EnableTimeout bool
// contains filtered or unexported fields
}
Gives the command the ability to create a context for its execution.
func NewContextCommand ¶ added in v0.0.2
func NewContextCommand(enableTimeout bool) *ContextCommand
func (*ContextCommand) ConfigureFlags ¶
func (ctc *ContextCommand) ConfigureFlags(cmd *cobra.Command)
func (*ContextCommand) GetCommandContext ¶
func (ctc *ContextCommand) GetCommandContext() (*contexts.Context, context.CancelFunc)
Get a context suited for a command's primary function. This will include a timeout and a signal handler.
type ContextCommandInterface ¶ added in v0.0.2
type KubeClusterCommand ¶
type KubeClusterCommand struct {
KubernetesCommand
// contains filtered or unexported fields
}
Gives a command the ability to interact with Kubernetes clusters (all supported APIs).
func NewKubeClusterCommand ¶ added in v0.0.2
func NewKubeClusterCommand() *KubeClusterCommand
func (*KubeClusterCommand) ConfigureFlags ¶ added in v0.0.9
func (kcc *KubeClusterCommand) ConfigureFlags(cmd *cobra.Command)
func (*KubeClusterCommand) NewKubeClusterClient ¶ added in v0.0.9
func (kcc *KubeClusterCommand) NewKubeClusterClient() (kubecluster.ClientInterface, error)
type KubeClusterCommandInterface ¶ added in v0.0.2
type KubeClusterCommandInterface interface {
KubernetesCommandInterface
NewKubeClusterClient() (kubecluster.ClientInterface, error)
}
type KubernetesCommand ¶
type KubernetesCommand struct {
ConfigOverrides clientcmd.ConfigOverrides
ExplicitConfigPath string
}
Gives a command the ability to interact with Kubernetes API.
func NewKubernetesCommand ¶ added in v0.0.2
func NewKubernetesCommand() *KubernetesCommand
func (*KubernetesCommand) ConfigureFlags ¶
func (kc *KubernetesCommand) ConfigureFlags(cmd *cobra.Command)
func (*KubernetesCommand) GetClusterConfig ¶
func (kc *KubernetesCommand) GetClusterConfig() (*rest.Config, error)
Get the cluster configurations from the following sources, in order of precedence: 1. A provided "kubeconfig" flag 2. The default kubeconfig file, at ~/.kube/config 3. The in-cluster kubeconfig, if running in a pod
type KubernetesCommandInterface ¶ added in v0.0.2
type MockConfigFileCommandInterface ¶ added in v0.0.2
MockConfigFileCommandInterface is an autogenerated mock type for the ConfigFileCommandInterface type
func NewMockConfigFileCommandInterface ¶ added in v0.0.2
func NewMockConfigFileCommandInterface[T interface{}](t interface {
mock.TestingT
Cleanup(func())
}) *MockConfigFileCommandInterface[T]
NewMockConfigFileCommandInterface creates a new instance of MockConfigFileCommandInterface. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockConfigFileCommandInterface[T]) ConfigureFlags ¶ added in v0.0.2
func (_m *MockConfigFileCommandInterface[T]) ConfigureFlags(cmd *cobra.Command)
ConfigureFlags provides a mock function with given fields: cmd
func (*MockConfigFileCommandInterface[T]) EXPECT ¶ added in v0.0.2
func (_m *MockConfigFileCommandInterface[T]) EXPECT() *MockConfigFileCommandInterface_Expecter[T]
func (*MockConfigFileCommandInterface[T]) GenerateConfigSchema ¶ added in v0.0.2
func (_m *MockConfigFileCommandInterface[T]) GenerateConfigSchema() ([]byte, error)
GenerateConfigSchema provides a mock function with no fields
func (*MockConfigFileCommandInterface[T]) ReadConfigFile ¶ added in v0.0.2
func (_m *MockConfigFileCommandInterface[T]) ReadConfigFile(ctx context.Context) (T, error)
ReadConfigFile provides a mock function with given fields: ctx
type MockConfigFileCommandInterface_ConfigureFlags_Call ¶ added in v0.0.2
MockConfigFileCommandInterface_ConfigureFlags_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ConfigureFlags'
func (*MockConfigFileCommandInterface_ConfigureFlags_Call[T]) Return ¶ added in v0.0.2
func (_c *MockConfigFileCommandInterface_ConfigureFlags_Call[T]) Return() *MockConfigFileCommandInterface_ConfigureFlags_Call[T]
func (*MockConfigFileCommandInterface_ConfigureFlags_Call[T]) Run ¶ added in v0.0.2
func (_c *MockConfigFileCommandInterface_ConfigureFlags_Call[T]) Run(run func(cmd *cobra.Command)) *MockConfigFileCommandInterface_ConfigureFlags_Call[T]
func (*MockConfigFileCommandInterface_ConfigureFlags_Call[T]) RunAndReturn ¶ added in v0.0.2
func (_c *MockConfigFileCommandInterface_ConfigureFlags_Call[T]) RunAndReturn(run func(*cobra.Command)) *MockConfigFileCommandInterface_ConfigureFlags_Call[T]
type MockConfigFileCommandInterface_Expecter ¶ added in v0.0.2
type MockConfigFileCommandInterface_Expecter[T interface{}] struct {
// contains filtered or unexported fields
}
func (*MockConfigFileCommandInterface_Expecter[T]) ConfigureFlags ¶ added in v0.0.2
func (_e *MockConfigFileCommandInterface_Expecter[T]) ConfigureFlags(cmd interface{}) *MockConfigFileCommandInterface_ConfigureFlags_Call[T]
ConfigureFlags is a helper method to define mock.On call
- cmd *cobra.Command
func (*MockConfigFileCommandInterface_Expecter[T]) GenerateConfigSchema ¶ added in v0.0.2
func (_e *MockConfigFileCommandInterface_Expecter[T]) GenerateConfigSchema() *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]
GenerateConfigSchema is a helper method to define mock.On call
func (*MockConfigFileCommandInterface_Expecter[T]) ReadConfigFile ¶ added in v0.0.2
func (_e *MockConfigFileCommandInterface_Expecter[T]) ReadConfigFile(ctx interface{}) *MockConfigFileCommandInterface_ReadConfigFile_Call[T]
ReadConfigFile is a helper method to define mock.On call
- ctx context.Context
type MockConfigFileCommandInterface_GenerateConfigSchema_Call ¶ added in v0.0.2
MockConfigFileCommandInterface_GenerateConfigSchema_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GenerateConfigSchema'
func (*MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]) Return ¶ added in v0.0.2
func (_c *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]) Return(_a0 []byte, _a1 error) *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]
func (*MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]) Run ¶ added in v0.0.2
func (_c *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]) Run(run func()) *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]
func (*MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]) RunAndReturn ¶ added in v0.0.2
func (_c *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]) RunAndReturn(run func() ([]byte, error)) *MockConfigFileCommandInterface_GenerateConfigSchema_Call[T]
type MockConfigFileCommandInterface_ReadConfigFile_Call ¶ added in v0.0.2
MockConfigFileCommandInterface_ReadConfigFile_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ReadConfigFile'
func (*MockConfigFileCommandInterface_ReadConfigFile_Call[T]) Return ¶ added in v0.0.2
func (_c *MockConfigFileCommandInterface_ReadConfigFile_Call[T]) Return(_a0 T, _a1 error) *MockConfigFileCommandInterface_ReadConfigFile_Call[T]
func (*MockConfigFileCommandInterface_ReadConfigFile_Call[T]) Run ¶ added in v0.0.2
func (_c *MockConfigFileCommandInterface_ReadConfigFile_Call[T]) Run(run func(ctx context.Context)) *MockConfigFileCommandInterface_ReadConfigFile_Call[T]
func (*MockConfigFileCommandInterface_ReadConfigFile_Call[T]) RunAndReturn ¶ added in v0.0.2
func (_c *MockConfigFileCommandInterface_ReadConfigFile_Call[T]) RunAndReturn(run func(context.Context) (T, error)) *MockConfigFileCommandInterface_ReadConfigFile_Call[T]
type MockContextCommandInterface ¶ added in v0.0.2
MockContextCommandInterface is an autogenerated mock type for the ContextCommandInterface type
func NewMockContextCommandInterface ¶ added in v0.0.2
func NewMockContextCommandInterface(t interface {
mock.TestingT
Cleanup(func())
}) *MockContextCommandInterface
NewMockContextCommandInterface creates a new instance of MockContextCommandInterface. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockContextCommandInterface) ConfigureFlags ¶ added in v0.0.2
func (_m *MockContextCommandInterface) ConfigureFlags(cmd *cobra.Command)
ConfigureFlags provides a mock function with given fields: cmd
func (*MockContextCommandInterface) EXPECT ¶ added in v0.0.2
func (_m *MockContextCommandInterface) EXPECT() *MockContextCommandInterface_Expecter
func (*MockContextCommandInterface) GetCommandContext ¶ added in v0.0.2
func (_m *MockContextCommandInterface) GetCommandContext() (*contexts.Context, context.CancelFunc)
GetCommandContext provides a mock function with no fields
type MockContextCommandInterface_ConfigureFlags_Call ¶ added in v0.0.2
MockContextCommandInterface_ConfigureFlags_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ConfigureFlags'
func (*MockContextCommandInterface_ConfigureFlags_Call) Run ¶ added in v0.0.2
func (_c *MockContextCommandInterface_ConfigureFlags_Call) Run(run func(cmd *cobra.Command)) *MockContextCommandInterface_ConfigureFlags_Call
func (*MockContextCommandInterface_ConfigureFlags_Call) RunAndReturn ¶ added in v0.0.2
func (_c *MockContextCommandInterface_ConfigureFlags_Call) RunAndReturn(run func(*cobra.Command)) *MockContextCommandInterface_ConfigureFlags_Call
type MockContextCommandInterface_Expecter ¶ added in v0.0.2
type MockContextCommandInterface_Expecter struct {
// contains filtered or unexported fields
}
func (*MockContextCommandInterface_Expecter) ConfigureFlags ¶ added in v0.0.2
func (_e *MockContextCommandInterface_Expecter) ConfigureFlags(cmd interface{}) *MockContextCommandInterface_ConfigureFlags_Call
ConfigureFlags is a helper method to define mock.On call
- cmd *cobra.Command
func (*MockContextCommandInterface_Expecter) GetCommandContext ¶ added in v0.0.2
func (_e *MockContextCommandInterface_Expecter) GetCommandContext() *MockContextCommandInterface_GetCommandContext_Call
GetCommandContext is a helper method to define mock.On call
type MockContextCommandInterface_GetCommandContext_Call ¶ added in v0.0.2
MockContextCommandInterface_GetCommandContext_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetCommandContext'
func (*MockContextCommandInterface_GetCommandContext_Call) Return ¶ added in v0.0.2
func (_c *MockContextCommandInterface_GetCommandContext_Call) Return(_a0 *contexts.Context, _a1 context.CancelFunc) *MockContextCommandInterface_GetCommandContext_Call
func (*MockContextCommandInterface_GetCommandContext_Call) Run ¶ added in v0.0.2
func (_c *MockContextCommandInterface_GetCommandContext_Call) Run(run func()) *MockContextCommandInterface_GetCommandContext_Call
func (*MockContextCommandInterface_GetCommandContext_Call) RunAndReturn ¶ added in v0.0.2
func (_c *MockContextCommandInterface_GetCommandContext_Call) RunAndReturn(run func() (*contexts.Context, context.CancelFunc)) *MockContextCommandInterface_GetCommandContext_Call
type MockKubeClusterCommandInterface ¶ added in v0.0.2
MockKubeClusterCommandInterface is an autogenerated mock type for the KubeClusterCommandInterface type
func NewMockKubeClusterCommandInterface ¶ added in v0.0.2
func NewMockKubeClusterCommandInterface(t interface {
mock.TestingT
Cleanup(func())
}) *MockKubeClusterCommandInterface
NewMockKubeClusterCommandInterface creates a new instance of MockKubeClusterCommandInterface. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockKubeClusterCommandInterface) ConfigureFlags ¶ added in v0.0.2
func (_m *MockKubeClusterCommandInterface) ConfigureFlags(cmd *cobra.Command)
ConfigureFlags provides a mock function with given fields: cmd
func (*MockKubeClusterCommandInterface) EXPECT ¶ added in v0.0.2
func (_m *MockKubeClusterCommandInterface) EXPECT() *MockKubeClusterCommandInterface_Expecter
func (*MockKubeClusterCommandInterface) GetClusterConfig ¶ added in v0.0.2
func (_m *MockKubeClusterCommandInterface) GetClusterConfig() (*rest.Config, error)
GetClusterConfig provides a mock function with no fields
func (*MockKubeClusterCommandInterface) NewKubeClusterClient ¶ added in v0.0.2
func (_m *MockKubeClusterCommandInterface) NewKubeClusterClient() (kubecluster.ClientInterface, error)
NewKubeClusterClient provides a mock function with no fields
type MockKubeClusterCommandInterface_ConfigureFlags_Call ¶ added in v0.0.2
MockKubeClusterCommandInterface_ConfigureFlags_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ConfigureFlags'
func (*MockKubeClusterCommandInterface_ConfigureFlags_Call) Run ¶ added in v0.0.2
func (_c *MockKubeClusterCommandInterface_ConfigureFlags_Call) Run(run func(cmd *cobra.Command)) *MockKubeClusterCommandInterface_ConfigureFlags_Call
func (*MockKubeClusterCommandInterface_ConfigureFlags_Call) RunAndReturn ¶ added in v0.0.2
func (_c *MockKubeClusterCommandInterface_ConfigureFlags_Call) RunAndReturn(run func(*cobra.Command)) *MockKubeClusterCommandInterface_ConfigureFlags_Call
type MockKubeClusterCommandInterface_Expecter ¶ added in v0.0.2
type MockKubeClusterCommandInterface_Expecter struct {
// contains filtered or unexported fields
}
func (*MockKubeClusterCommandInterface_Expecter) ConfigureFlags ¶ added in v0.0.2
func (_e *MockKubeClusterCommandInterface_Expecter) ConfigureFlags(cmd interface{}) *MockKubeClusterCommandInterface_ConfigureFlags_Call
ConfigureFlags is a helper method to define mock.On call
- cmd *cobra.Command
func (*MockKubeClusterCommandInterface_Expecter) GetClusterConfig ¶ added in v0.0.2
func (_e *MockKubeClusterCommandInterface_Expecter) GetClusterConfig() *MockKubeClusterCommandInterface_GetClusterConfig_Call
GetClusterConfig is a helper method to define mock.On call
func (*MockKubeClusterCommandInterface_Expecter) NewKubeClusterClient ¶ added in v0.0.2
func (_e *MockKubeClusterCommandInterface_Expecter) NewKubeClusterClient() *MockKubeClusterCommandInterface_NewKubeClusterClient_Call
NewKubeClusterClient is a helper method to define mock.On call
type MockKubeClusterCommandInterface_GetClusterConfig_Call ¶ added in v0.0.2
MockKubeClusterCommandInterface_GetClusterConfig_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetClusterConfig'
func (*MockKubeClusterCommandInterface_GetClusterConfig_Call) Return ¶ added in v0.0.2
func (_c *MockKubeClusterCommandInterface_GetClusterConfig_Call) Return(_a0 *rest.Config, _a1 error) *MockKubeClusterCommandInterface_GetClusterConfig_Call
func (*MockKubeClusterCommandInterface_GetClusterConfig_Call) Run ¶ added in v0.0.2
func (_c *MockKubeClusterCommandInterface_GetClusterConfig_Call) Run(run func()) *MockKubeClusterCommandInterface_GetClusterConfig_Call
func (*MockKubeClusterCommandInterface_GetClusterConfig_Call) RunAndReturn ¶ added in v0.0.2
func (_c *MockKubeClusterCommandInterface_GetClusterConfig_Call) RunAndReturn(run func() (*rest.Config, error)) *MockKubeClusterCommandInterface_GetClusterConfig_Call
type MockKubeClusterCommandInterface_NewKubeClusterClient_Call ¶ added in v0.0.2
MockKubeClusterCommandInterface_NewKubeClusterClient_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'NewKubeClusterClient'
func (*MockKubeClusterCommandInterface_NewKubeClusterClient_Call) Run ¶ added in v0.0.2
func (_c *MockKubeClusterCommandInterface_NewKubeClusterClient_Call) Run(run func()) *MockKubeClusterCommandInterface_NewKubeClusterClient_Call
func (*MockKubeClusterCommandInterface_NewKubeClusterClient_Call) RunAndReturn ¶ added in v0.0.2
func (_c *MockKubeClusterCommandInterface_NewKubeClusterClient_Call) RunAndReturn(run func() (kubecluster.ClientInterface, error)) *MockKubeClusterCommandInterface_NewKubeClusterClient_Call
type MockKubernetesCommandInterface ¶ added in v0.0.2
MockKubernetesCommandInterface is an autogenerated mock type for the KubernetesCommandInterface type
func NewMockKubernetesCommandInterface ¶ added in v0.0.2
func NewMockKubernetesCommandInterface(t interface {
mock.TestingT
Cleanup(func())
}) *MockKubernetesCommandInterface
NewMockKubernetesCommandInterface creates a new instance of MockKubernetesCommandInterface. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockKubernetesCommandInterface) ConfigureFlags ¶ added in v0.0.2
func (_m *MockKubernetesCommandInterface) ConfigureFlags(cmd *cobra.Command)
ConfigureFlags provides a mock function with given fields: cmd
func (*MockKubernetesCommandInterface) EXPECT ¶ added in v0.0.2
func (_m *MockKubernetesCommandInterface) EXPECT() *MockKubernetesCommandInterface_Expecter
func (*MockKubernetesCommandInterface) GetClusterConfig ¶ added in v0.0.2
func (_m *MockKubernetesCommandInterface) GetClusterConfig() (*rest.Config, error)
GetClusterConfig provides a mock function with no fields
type MockKubernetesCommandInterface_ConfigureFlags_Call ¶ added in v0.0.2
MockKubernetesCommandInterface_ConfigureFlags_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ConfigureFlags'
func (*MockKubernetesCommandInterface_ConfigureFlags_Call) Run ¶ added in v0.0.2
func (_c *MockKubernetesCommandInterface_ConfigureFlags_Call) Run(run func(cmd *cobra.Command)) *MockKubernetesCommandInterface_ConfigureFlags_Call
func (*MockKubernetesCommandInterface_ConfigureFlags_Call) RunAndReturn ¶ added in v0.0.2
func (_c *MockKubernetesCommandInterface_ConfigureFlags_Call) RunAndReturn(run func(*cobra.Command)) *MockKubernetesCommandInterface_ConfigureFlags_Call
type MockKubernetesCommandInterface_Expecter ¶ added in v0.0.2
type MockKubernetesCommandInterface_Expecter struct {
// contains filtered or unexported fields
}
func (*MockKubernetesCommandInterface_Expecter) ConfigureFlags ¶ added in v0.0.2
func (_e *MockKubernetesCommandInterface_Expecter) ConfigureFlags(cmd interface{}) *MockKubernetesCommandInterface_ConfigureFlags_Call
ConfigureFlags is a helper method to define mock.On call
- cmd *cobra.Command
func (*MockKubernetesCommandInterface_Expecter) GetClusterConfig ¶ added in v0.0.2
func (_e *MockKubernetesCommandInterface_Expecter) GetClusterConfig() *MockKubernetesCommandInterface_GetClusterConfig_Call
GetClusterConfig is a helper method to define mock.On call
type MockKubernetesCommandInterface_GetClusterConfig_Call ¶ added in v0.0.2
MockKubernetesCommandInterface_GetClusterConfig_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetClusterConfig'
func (*MockKubernetesCommandInterface_GetClusterConfig_Call) Return ¶ added in v0.0.2
func (_c *MockKubernetesCommandInterface_GetClusterConfig_Call) Return(_a0 *rest.Config, _a1 error) *MockKubernetesCommandInterface_GetClusterConfig_Call
func (*MockKubernetesCommandInterface_GetClusterConfig_Call) Run ¶ added in v0.0.2
func (_c *MockKubernetesCommandInterface_GetClusterConfig_Call) Run(run func()) *MockKubernetesCommandInterface_GetClusterConfig_Call
func (*MockKubernetesCommandInterface_GetClusterConfig_Call) RunAndReturn ¶ added in v0.0.2
func (_c *MockKubernetesCommandInterface_GetClusterConfig_Call) RunAndReturn(run func() (*rest.Config, error)) *MockKubernetesCommandInterface_GetClusterConfig_Call