Documentation ¶
Index ¶
- type MockClient
- func (m *MockClient) Create(ctx context.Context, obj ctrlClient.Object, opts ...ctrlClient.CreateOption) error
- func (m *MockClient) Delete(ctx context.Context, obj ctrlClient.Object, opts ...ctrlClient.DeleteOption) error
- func (m *MockClient) DeleteAllOf(ctx context.Context, obj ctrlClient.Object, ...) error
- func (m *MockClient) Get(ctx context.Context, key ctrlClient.ObjectKey, obj ctrlClient.Object, ...) error
- func (m *MockClient) GroupVersionKindFor(obj runtime.Object) (schema.GroupVersionKind, error)
- func (m *MockClient) IsObjectNamespaced(obj runtime.Object) (bool, error)
- func (m *MockClient) List(ctx context.Context, list ctrlClient.ObjectList, opts ...ctrlClient.ListOption) error
- func (m *MockClient) Patch(ctx context.Context, obj ctrlClient.Object, patch ctrlClient.Patch, ...) error
- func (m *MockClient) RESTMapper() meta.RESTMapper
- func (m *MockClient) Scheme() *runtime.Scheme
- func (m *MockClient) Status() ctrlClient.SubResourceWriter
- func (m *MockClient) SubResource(subResource string) ctrlClient.SubResourceClient
- func (m *MockClient) Update(ctx context.Context, obj ctrlClient.Object, opts ...ctrlClient.UpdateOption) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockClient ¶
func NewMockClient ¶
func NewMockClient() *MockClient
NewMockClient returns a MockClient that is a mocked sigs.k8s.io/controller-runtime/pkg/client and can be used to mock calls to the Kubernetes API during unit tests
func (*MockClient) Create ¶
func (m *MockClient) Create(ctx context.Context, obj ctrlClient.Object, opts ...ctrlClient.CreateOption) error
func (*MockClient) Delete ¶
func (m *MockClient) Delete(ctx context.Context, obj ctrlClient.Object, opts ...ctrlClient.DeleteOption) error
func (*MockClient) DeleteAllOf ¶
func (m *MockClient) DeleteAllOf(ctx context.Context, obj ctrlClient.Object, opts ...ctrlClient.DeleteAllOfOption) error
func (*MockClient) Get ¶
func (m *MockClient) Get(ctx context.Context, key ctrlClient.ObjectKey, obj ctrlClient.Object, opts ...ctrlClient.GetOption) error
func (*MockClient) GroupVersionKindFor ¶
func (m *MockClient) GroupVersionKindFor(obj runtime.Object) (schema.GroupVersionKind, error)
func (*MockClient) IsObjectNamespaced ¶
func (m *MockClient) IsObjectNamespaced(obj runtime.Object) (bool, error)
func (*MockClient) List ¶
func (m *MockClient) List(ctx context.Context, list ctrlClient.ObjectList, opts ...ctrlClient.ListOption) error
func (*MockClient) Patch ¶
func (m *MockClient) Patch(ctx context.Context, obj ctrlClient.Object, patch ctrlClient.Patch, opts ...ctrlClient.PatchOption) error
func (*MockClient) RESTMapper ¶
func (m *MockClient) RESTMapper() meta.RESTMapper
func (*MockClient) Scheme ¶
func (m *MockClient) Scheme() *runtime.Scheme
func (*MockClient) Status ¶
func (m *MockClient) Status() ctrlClient.SubResourceWriter
func (*MockClient) SubResource ¶
func (m *MockClient) SubResource(subResource string) ctrlClient.SubResourceClient
func (*MockClient) Update ¶
func (m *MockClient) Update(ctx context.Context, obj ctrlClient.Object, opts ...ctrlClient.UpdateOption) error
Click to show internal directories.
Click to hide internal directories.