package fake
import "k8s.io/client-go/dynamic/fake"
Index ¶
- type FakeDynamicClient
- func NewSimpleDynamicClient(scheme *runtime.Scheme, objects ...runtime.Object) *FakeDynamicClient
- func NewSimpleDynamicClientWithCustomListKinds(scheme *runtime.Scheme, gvrToListKind map[schema.GroupVersionResource]string, objects ...runtime.Object) *FakeDynamicClient
- func (c *FakeDynamicClient) Resource(resource schema.GroupVersionResource) dynamic.NamespaceableResourceInterface
- func (c *FakeDynamicClient) Tracker() testing.ObjectTracker
Types ¶
type FakeDynamicClient ¶
Clientset implements clientset.Interface. Meant to be embedded into a struct to get a default implementation. This makes faking out just the method you want to test easier.
func NewSimpleDynamicClient ¶
func NewSimpleDynamicClient(scheme *runtime.Scheme, objects ...runtime.Object) *FakeDynamicClient
func NewSimpleDynamicClientWithCustomListKinds ¶
func NewSimpleDynamicClientWithCustomListKinds(scheme *runtime.Scheme, gvrToListKind map[schema.GroupVersionResource]string, objects ...runtime.Object) *FakeDynamicClient
NewSimpleDynamicClientWithCustomListKinds try not to use this. In general you want to have the scheme have the List types registered and allow the default guessing for resources match. Sometimes that doesn't work, so you can specify a custom mapping here.
func (*FakeDynamicClient) Resource ¶
func (c *FakeDynamicClient) Resource(resource schema.GroupVersionResource) dynamic.NamespaceableResourceInterface
func (*FakeDynamicClient) Tracker ¶
func (c *FakeDynamicClient) Tracker() testing.ObjectTracker
Source Files ¶
simple.go
- Version
- v0.33.0 (latest)
- Published
- Apr 23, 2025
- Platform
- linux/amd64
- Imports
- 14 packages
- Last checked
- 1 hour ago –
Tools for package owners.