mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-26 21:17:23 +00:00
Populates the fake dynamic client scheme
This commit is contained in:
parent
b637ae6515
commit
db20e16b87
@ -45,7 +45,7 @@ func NewSimpleDynamicClient(scheme *runtime.Scheme, objects ...runtime.Object) *
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
cs := &FakeDynamicClient{}
|
cs := &FakeDynamicClient{scheme: scheme}
|
||||||
cs.AddReactor("*", "*", testing.ObjectReaction(o))
|
cs.AddReactor("*", "*", testing.ObjectReaction(o))
|
||||||
cs.AddWatchReactor("*", func(action testing.Action) (handled bool, ret watch.Interface, err error) {
|
cs.AddWatchReactor("*", func(action testing.Action) (handled bool, ret watch.Interface, err error) {
|
||||||
gvr := action.GetResource()
|
gvr := action.GetResource()
|
||||||
|
Loading…
Reference in New Issue
Block a user