From ab38a78d705bc73b4f7b8fc3ce7848ae8a09f1ed Mon Sep 17 00:00:00 2001 From: Zach Loafman Date: Wed, 11 Feb 2015 13:11:03 -0800 Subject: [PATCH] Test() was mis-tracked. Change the variable name / handling here, and also just make it unset so that if it's ever uninitialized it's obvious. Fixes #4177 --- hack/e2e.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/hack/e2e.go b/hack/e2e.go index 4a828d588ba..4c3cb8eef48 100644 --- a/hack/e2e.go +++ b/hack/e2e.go @@ -146,21 +146,21 @@ func main() { } } - failure := false + success := true switch { case *ctlCmd != "": ctlArgs := strings.Fields(*ctlCmd) os.Setenv("KUBE_CONFIG_FILE", "config-test.sh") - failure = !finishRunning("'kubectl "+*ctlCmd+"'", exec.Command(path.Join(versionRoot, "cluster/kubectl.sh"), ctlArgs...)) + success = finishRunning("'kubectl "+*ctlCmd+"'", exec.Command(path.Join(versionRoot, "cluster/kubectl.sh"), ctlArgs...)) case *test: - failure = Test() + success = Test() } if *down { TearDown() } - if failure { + if !success { os.Exit(1) } }