From 8d897fd51f661c4bc5d8eb485285e32ead0c4f4e Mon Sep 17 00:00:00 2001 From: Anthony Romano Date: Mon, 18 Jul 2016 16:42:08 -0700 Subject: [PATCH] integration: use unix sockets in TestEmbedEtcd Was getting tcp port conflicts in semphore even after assigning unique ports. Fixes #5953 --- integration/embed_test.go | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/integration/embed_test.go b/integration/embed_test.go index f656ffb97..1a8075bc5 100644 --- a/integration/embed_test.go +++ b/integration/embed_test.go @@ -88,15 +88,11 @@ func TestEmbedEtcd(t *testing.T) { } } -// 4000x so no conflict with e2e tests -var embedBasePort = 40000 - func newEmbedURLs(n int) (urls []url.URL) { for i := 0; i < n; i++ { - u, _ := url.Parse(fmt.Sprintf("http://localhost:%d", embedBasePort+i)) + u, _ := url.Parse(fmt.Sprintf("unix://localhost:%d.%d.sock", os.Getpid(), i)) urls = append(urls, *u) } - embedBasePort += n return }