2014-06-19 05:59:46 +04:00
box : yosssi/golang-latest@1.0.4
2014-06-17 09:44:09 +04:00
# Build definition
build :
# The steps that will be executed on build
steps :
# Sets the go workspace and places you package
# at the right place in the workspace tree
- setup-go-workspace
# Gets the dependencies
- script :
name : go get
code : |
cd $WERCKER_SOURCE_DIR
go version
go get -t ./...
# Build the project
- script :
name : go build
code : |
go build ./...
# Test the project
- script :
name : go test
code : |
2014-06-18 09:29:24 +04:00
go test -cover ./...
2014-06-17 10:52:49 +04:00
# Invoke goveralls
- script :
name : goveralls
code : |
go get github.com/mattn/goveralls
2014-06-17 11:45:11 +04:00
echo "mode: count" > all.cov
2014-06-17 11:56:36 +04:00
for package in reaper shared/protobuf shared store; do touch $package.cov; go test --covermode=count -coverprofile=$package.cov ./$package; sed -e "1d" $package.cov >> all.cov; done
2014-06-17 11:45:11 +04:00
goveralls -coverprofile=all.cov -service=wercker.com -repotoken $COVERALLS_REPO_TOKEN