forked from openshift/origin
-
Notifications
You must be signed in to change notification settings - Fork 0
/
fake_appliedclusterresourcequota.go
34 lines (26 loc) · 1.14 KB
/
fake_appliedclusterresourcequota.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
package testclient
import (
kapi "k8s.io/kubernetes/pkg/api"
"k8s.io/kubernetes/pkg/api/unversioned"
"k8s.io/kubernetes/pkg/client/testing/core"
quotaapi "github.com/openshift/origin/pkg/quota/api"
)
type FakeAppliedClusterResourceQuotas struct {
Fake *Fake
Namespace string
}
var appliedClusterResourceQuotasResource = unversioned.GroupVersionResource{Group: "", Version: "", Resource: "appliedclusterresourcequotas"}
func (c *FakeAppliedClusterResourceQuotas) Get(name string) (*quotaapi.AppliedClusterResourceQuota, error) {
obj, err := c.Fake.Invokes(core.NewGetAction(appliedClusterResourceQuotasResource, c.Namespace, name), "aapi.AppliedClusterResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*quotaapi.AppliedClusterResourceQuota), err
}
func (c *FakeAppliedClusterResourceQuotas) List(opts kapi.ListOptions) (*quotaapi.AppliedClusterResourceQuotaList, error) {
obj, err := c.Fake.Invokes(core.NewListAction(appliedClusterResourceQuotasResource, c.Namespace, opts), "aapi.AppliedClusterResourceQuotaList{})
if obj == nil {
return nil, err
}
return obj.(*quotaapi.AppliedClusterResourceQuotaList), err
}