From 51caf759c374812d5787a636bfb6ddfd33369cb1 Mon Sep 17 00:00:00 2001 From: Daniel Smith Date: Tue, 5 Aug 2014 16:20:15 -0700 Subject: [PATCH] Add WatchReplicationControllers to kubecfg's fake --- pkg/kubecfg/kubecfg_test.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkg/kubecfg/kubecfg_test.go b/pkg/kubecfg/kubecfg_test.go index 234a97619b8..b1bc55c0661 100644 --- a/pkg/kubecfg/kubecfg_test.go +++ b/pkg/kubecfg/kubecfg_test.go @@ -27,6 +27,7 @@ import ( "github.com/GoogleCloudPlatform/kubernetes/pkg/api" "github.com/GoogleCloudPlatform/kubernetes/pkg/client" "github.com/GoogleCloudPlatform/kubernetes/pkg/labels" + "github.com/GoogleCloudPlatform/kubernetes/pkg/watch" ) type Action struct { @@ -90,6 +91,11 @@ func (client *FakeKubeClient) DeleteReplicationController(controller string) err return nil } +func (client *FakeKubeClient) WatchReplicationControllers(label, field labels.Selector, resourceVersion uint64) (watch.Interface, error) { + client.actions = append(client.actions, Action{action: "watch-controllers"}) + return watch.NewFake(), nil +} + func (client *FakeKubeClient) GetService(name string) (api.Service, error) { client.actions = append(client.actions, Action{action: "get-service", value: name}) return api.Service{}, nil