etcd/test.sh

24 lines
370 B
Bash
Raw Normal View History

2013-07-30 02:57:37 +04:00
#!/bin/sh
2013-10-17 20:02:59 +04:00
set -e
2013-12-05 03:23:27 +04:00
if [ -z "$PKG" ]; then
2013-12-05 09:24:04 +04:00
PKG="./store ./server ./server/v2/tests ./mod/lock/v2/tests"
2013-12-05 03:23:27 +04:00
fi
2013-11-28 03:59:05 +04:00
# Get GOPATH, etc from build
. ./build
2013-10-18 07:57:00 +04:00
# use right GOPATH
export GOPATH="${PWD}"
# Unit tests
2013-12-05 03:23:27 +04:00
for i in $PKG
2013-11-28 03:59:05 +04:00
do
2013-12-05 03:23:27 +04:00
go test -i $i
go test -v $i
2013-11-28 03:59:05 +04:00
done
2013-10-18 04:11:11 +04:00
# Functional tests
2013-10-18 07:57:00 +04:00
go test -i ./tests/functional
ETCD_BIN_PATH=$(pwd)/etcd go test -v ./tests/functional