20 lines
497 B
Bash
Executable File
20 lines
497 B
Bash
Executable File
#!/bin/sh
|
|
#/ Usage: script/test # run all tests
|
|
#/ script/test <subdir> # run just a package's tests
|
|
|
|
script/fmt
|
|
script/bootstrap
|
|
|
|
export LOCALSRCDIR=`pwd`/.vendor/src/github.com/hawser/git-hawser
|
|
mkdir -p `dirname $LOCALSRCDIR`
|
|
rm -f $LOCALSRCDIR
|
|
ln -s `pwd` $LOCALSRCDIR
|
|
|
|
GOPATH="`pwd`/.vendor"
|
|
SUITE="./${1:-"..."}"
|
|
if [ $# -gt 0 ]; then
|
|
shift
|
|
fi
|
|
PATH=$LOCALSRCDIR/bin:$PATH GOPATH=$GOPATH go test $SUITE -i "$@"
|
|
PATH=$LOCALSRCDIR/bin:$PATH GOPATH=$GOPATH go test $SUITE "$@"
|