mirror of
https://github.com/kubernetes/client-go.git
synced 2025-08-22 08:56:50 +00:00
Merge pull request #133171 from p0lyn0mial/upstream-fake-metadata-client-opts-watch
client-go/metadata/fake: sets opts.Watch to true Kubernetes-commit: 3a99a64438d7f15e170889181f93bb1dc48c4888
This commit is contained in:
commit
f4919f808e
@ -354,6 +354,7 @@ func (c *metadataResourceClient) List(ctx context.Context, opts metav1.ListOptio
|
||||
}
|
||||
|
||||
func (c *metadataResourceClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
|
||||
opts.Watch = true
|
||||
switch {
|
||||
case len(c.namespace) == 0:
|
||||
return c.client.Fake.
|
||||
@ -362,7 +363,6 @@ func (c *metadataResourceClient) Watch(ctx context.Context, opts metav1.ListOpti
|
||||
case len(c.namespace) > 0:
|
||||
return c.client.Fake.
|
||||
InvokesWatch(testing.NewWatchAction(c.resource, c.namespace, opts))
|
||||
|
||||
}
|
||||
|
||||
panic("math broke")
|
||||
|
Loading…
Reference in New Issue
Block a user