diff --git a/test/e2e/roservice.go b/test/e2e/roservice.go deleted file mode 100644 index 421cbcdee7a..00000000000 --- a/test/e2e/roservice.go +++ /dev/null @@ -1,58 +0,0 @@ -/* -Copyright 2014 Google Inc. All rights reserved. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package e2e - -import ( - "fmt" - - "github.com/GoogleCloudPlatform/kubernetes/pkg/api" - "github.com/GoogleCloudPlatform/kubernetes/pkg/client" - - . "github.com/onsi/ginkgo" - . "github.com/onsi/gomega" -) - -var _ = Describe("TestKubernetesROService", func() { - var c *client.Client - - BeforeEach(func() { - c = loadClientOrDie() - }) - - It("should pass", func() { - svc := api.ServiceList{} - err := c.Get(). - Namespace("default"). - AbsPath("/api/v1beta1/proxy/services/kubernetes-ro/api/v1beta1/services"). - Do(). - Into(&svc) - if err != nil { - Fail(fmt.Sprintf("unexpected error listing services using ro service: %v", err)) - } - var foundRW, foundRO bool - for i := range svc.Items { - if svc.Items[i].Name == "kubernetes" { - foundRW = true - } - if svc.Items[i].Name == "kubernetes-ro" { - foundRO = true - } - } - Expect(foundRW).To(Equal(true)) - Expect(foundRO).To(Equal(true)) - }) -}) diff --git a/test/e2e/service.go b/test/e2e/service.go index 4880615720b..781fbfdea37 100644 --- a/test/e2e/service.go +++ b/test/e2e/service.go @@ -154,4 +154,27 @@ var _ = Describe("Services", func() { fmt.Printf("DNS probes using %s succeeded\n", pod.Name) } }) + + It("should provide RW and RO services", func() { + svc := api.ServiceList{} + err := c.Get(). + Namespace("default"). + AbsPath("/api/v1beta1/proxy/services/kubernetes-ro/api/v1beta1/services"). + Do(). + Into(&svc) + if err != nil { + Fail(fmt.Sprintf("unexpected error listing services using ro service: %v", err)) + } + var foundRW, foundRO bool + for i := range svc.Items { + if svc.Items[i].Name == "kubernetes" { + foundRW = true + } + if svc.Items[i].Name == "kubernetes-ro" { + foundRO = true + } + } + Expect(foundRW).To(Equal(true)) + Expect(foundRO).To(Equal(true)) + }) })