1
0
mirror of https://github.com/volatiletech/authboss.git synced 2025-01-10 04:17:59 +02:00
authboss/circle.yml

33 lines
1.2 KiB
YAML

machine:
environment:
GOPATH: "${HOME}/.go_project"
checkout:
post:
- mkdir -p /home/ubuntu/.go_project/src/gopkg.in
- ln -s /home/ubuntu/authboss /home/ubuntu/.go_project/src/gopkg.in/authboss.v0
dependencies:
override:
- cd /home/ubuntu/.go_project/src/gopkg.in/authboss.v0 && go get -t -d -v ./...
- cd /home/ubuntu/.go_project/src/gopkg.in/authboss.v0 && go build -v
test:
pre:
- go get github.com/jstemmer/go-junit-report
- go get github.com/mattn/goveralls
override:
- >
cd /home/ubuntu/.go_project/src/gopkg.in/authboss.v0 &&
go test -v -race ./... |
/home/ubuntu/.go_project/bin/go-junit-report >> $CIRCLE_TEST_REPORTS/junit.xml
- >
cd /home/ubuntu/.go_project/src/gopkg.in/authboss.v0 &&
echo "mode: set" > $CIRCLE_ARTIFACTS/coverage.txt &&
for i in $(go list ./...); do
rm -f coverage.tmp;
go test -v -coverprofile coverage.tmp $i &&
tail -n +2 coverage.tmp >> $CIRCLE_ARTIFACTS/coverage.txt;
done
post:
- >
cd /home/ubuntu/.go_project/src/gopkg.in/authboss.v0 &&
/home/ubuntu/.go_project/bin/goveralls -coverprofile=$CIRCLE_ARTIFACTS/coverage.txt -service=circle-ci -repotoken=$COVERALLS_TOKEN