mirror of https://github.com/status-im/consul.git
Build consul to a temp dir for API tests
This commit is contained in:
parent
a54e8678a1
commit
9bdf570fa5
4
Makefile
4
Makefile
|
@ -20,8 +20,8 @@ updatedeps: deps
|
||||||
@go get -d -f -u ./... $(DEPS)
|
@go get -d -f -u ./... $(DEPS)
|
||||||
|
|
||||||
test: deps
|
test: deps
|
||||||
./scripts/verify_no_uuid.sh
|
@./scripts/verify_no_uuid.sh
|
||||||
go list ./... | xargs -n1 go test
|
@./scripts/test.sh
|
||||||
@$(MAKE) vet
|
@$(MAKE) vet
|
||||||
|
|
||||||
integ:
|
integ:
|
||||||
|
|
|
@ -0,0 +1,13 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Create a temp dir and clean it up on exit
|
||||||
|
TEMPDIR=`mktemp -d -t consul-test`
|
||||||
|
trap "rm -rf $TEMPDIR" EXIT HUP INT QUIT TERM
|
||||||
|
|
||||||
|
# Build the Consul binary for the API tests
|
||||||
|
echo "--> Building consul"
|
||||||
|
go build -o $TEMPDIR/consul || exit 1
|
||||||
|
|
||||||
|
# Run the tests
|
||||||
|
echo "--> Running tests"
|
||||||
|
go list ./... | PATH=$TEMPDIR:$PATH xargs -n1 go test
|
Loading…
Reference in New Issue