From cc0f460033ee7ef75a45cb1d1709af484b4632c5 Mon Sep 17 00:00:00 2001 From: Ferran Rodenas Date: Sat, 21 Jan 2017 19:32:18 +0100 Subject: [PATCH] Fake tillerHost at version cmd tests Version cmd tries to set up a tunnel at RunE instead of using the PersistentPreRunE. That means that for each version test (3) it tries to set up the tunnel. When running the tests on an internetless or whithout a valid k8s environment, the tunnel will fail with a timeout of 20 seconds, meaning that it will take 60 seconds to run the test. This commit adds a fake tillerHost so it will not try to setup the tunnel. --- cmd/helm/version_test.go | 1 + 1 file changed, 1 insertion(+) diff --git a/cmd/helm/version_test.go b/cmd/helm/version_test.go index 365f97c71..5f204b789 100644 --- a/cmd/helm/version_test.go +++ b/cmd/helm/version_test.go @@ -39,6 +39,7 @@ func TestVersion(t *testing.T) { {"server", false, true, []string{"-s"}, false}, } + tillerHost = "fake-localhost" for _, tt := range tests { b := new(bytes.Buffer) c := &fakeReleaseClient{}