Blob Blame History Raw
From a144093e502d4529d598ecf997fea9e261ac595d Mon Sep 17 00:00:00 2001
From: Jan Chaloupka <jchaloup@redhat.com>
Date: Mon, 15 Aug 2016 16:09:52 +0200
Subject: [PATCH] hack test

---
 test | 26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/test b/test
index 4f24606..deaa527 100755
--- a/test
+++ b/test
@@ -53,7 +53,7 @@ fi
 function unit_tests {
 	echo "Running tests..."
 	# only -run=Test so examples can run in integration tests
-	go test -timeout 3m ${COVER} ${RACE} -cpu 1,2,4 -run=Test $@ ${TEST}
+	${GOTEST:-go test} -timeout 3m ${COVER} ${RACE} -cpu 1,2,4 -run=Test $@ ${TEST}
 }
 
 function integration_tests {
@@ -69,16 +69,16 @@ function integration_tests {
 		mv /tmp/etcd ./bin/etcd-last-release
 	fi;
 
-	go test -timeout 10m -v -cpu 1,2,4 $@ ${REPO_PATH}/e2e &
+	${GOTEST:-go test} -timeout 10m -v -cpu 1,2,4 $@ ${REPO_PATH}/e2e &
 	e2epid="$!"
-	go test -timeout 15m -v -cpu 1,2,4 $@ ${REPO_PATH}/integration &
+	${GOTEST:-go test} -timeout 15m -v -cpu 1,2,4 $@ ${REPO_PATH}/integration &
 	intpid="$!"
 	wait $e2epid
 	wait $intpid
-	go test -timeout 1m -v ${RACE} -cpu 1,2,4 $@ ${REPO_PATH}/client/integration
-	go test -timeout 10m -v ${RACE} -cpu 1,2,4 $@ ${REPO_PATH}/clientv3/integration
-	go test -timeout 1m -v -cpu 1,2,4 $@ ${REPO_PATH}/contrib/raftexample
-	go test -timeout 1m -v ${RACE} -cpu 1,2,4 -run=Example $@ ${TEST}
+	${GOTEST:-go test} -timeout 1m -v ${RACE} -cpu 1,2,4 $@ ${REPO_PATH}/client/integration
+	${GOTEST:-go test} -timeout 10m -v ${RACE} -cpu 1,2,4 $@ ${REPO_PATH}/clientv3/integration
+	${GOTEST:-go test} -timeout 1m -v -cpu 1,2,4 $@ ${REPO_PATH}/contrib/raftexample
+	${GOTEST:-go test} -timeout 1m -v ${RACE} -cpu 1,2,4 -run=Example $@ ${TEST}
 }
 
 function fmt_tests {
@@ -197,18 +197,18 @@ function dep_tests {
 }
 
 # Set up gopath so tests use vendored dependencies
-export GOPATH=${PWD}/gopath
-rm -rf $GOPATH/src
-mkdir -p $GOPATH
-ln -s ${PWD}/cmd/vendor $GOPATH/src
+#export GOPATH=${PWD}/Godeps/_workspace
+#rm -rf $GOPATH/src
+#mkdir -p $GOPATH
+#ln -s ${PWD}/cmd/vendor $GOPATH/src
 
 # fail fast on static tests
 toggle_failpoints disable
-fmt_tests
+#fmt_tests
 dep_tests
 
 # fail fast on static tests
-GO_BUILD_FLAGS="-a -v" etcd_build
+#GO_BUILD_FLAGS="-a -v" etcd_build
 
 unit_tests
 if [ -n "$INTEGRATION" ]; then
-- 
1.9.3