mirror of
https://github.com/kubernetes/client-go.git
synced 2025-09-02 07:35:21 +00:00
Add support for JSON patch in fake client
Kubernetes-commit: a363b153851326ece7f81f4c1ae0a1ab8700a209
This commit is contained in:
committed by
Kubernetes Publisher
parent
cbd9965a0e
commit
41406bf985
@@ -112,7 +112,7 @@ func (c *FakePriorityClasses) DeleteCollection(options *v1.DeleteOptions, listOp
|
||||
// Patch applies the patch and returns the patched priorityClass.
|
||||
func (c *FakePriorityClasses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.PriorityClass, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootPatchSubresourceAction(priorityclassesResource, name, data, subresources...), &v1alpha1.PriorityClass{})
|
||||
Invokes(testing.NewRootPatchSubresourceAction(priorityclassesResource, name, pt, data, subresources...), &v1alpha1.PriorityClass{})
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
|
@@ -112,7 +112,7 @@ func (c *FakePriorityClasses) DeleteCollection(options *v1.DeleteOptions, listOp
|
||||
// Patch applies the patch and returns the patched priorityClass.
|
||||
func (c *FakePriorityClasses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.PriorityClass, err error) {
|
||||
obj, err := c.Fake.
|
||||
Invokes(testing.NewRootPatchSubresourceAction(priorityclassesResource, name, data, subresources...), &v1beta1.PriorityClass{})
|
||||
Invokes(testing.NewRootPatchSubresourceAction(priorityclassesResource, name, pt, data, subresources...), &v1beta1.PriorityClass{})
|
||||
if obj == nil {
|
||||
return nil, err
|
||||
}
|
||||
|
Reference in New Issue
Block a user