From d64b684831aff2df86d9cea8e23bf57c85b6772f Mon Sep 17 00:00:00 2001 From: Miek Gieben Date: Fri, 20 Oct 2017 22:53:17 +0100 Subject: plugin/kubernetes: implement HasSynced() (#1155) * plugin/kubernetes: wait until api is ready Wait for HasSynced before allowing startup to avoid startup race. Also do a small refactor in findServices() to pull a check out of the loop - only needs to be done once. * sigh --- test/kubernetes_api_fallthrough_test.go | 4 ---- 1 file changed, 4 deletions(-) (limited to 'test/kubernetes_api_fallthrough_test.go') diff --git a/test/kubernetes_api_fallthrough_test.go b/test/kubernetes_api_fallthrough_test.go index 08d380f67..d12789c24 100644 --- a/test/kubernetes_api_fallthrough_test.go +++ b/test/kubernetes_api_fallthrough_test.go @@ -4,7 +4,6 @@ package test import ( "testing" - "time" "github.com/coredns/coredns/plugin/test" @@ -36,9 +35,6 @@ func TestKubernetesAPIFallthrough(t *testing.T) { } defer server.Stop() - // Work-around for timing condition that results in no-data being returned in test environment. - time.Sleep(3 * time.Second) - for _, tc := range tests { c := new(dns.Client) -- cgit v1.2.3