parent
cb6d388138
commit
9fb98cfb33
|
@ -1,12 +1,8 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# Issue: https://github.com/mattn/goveralls/issues/20
|
# Issue: https://github.com/mattn/goveralls/issues/20
|
||||||
# Source: https://github.com/uber/go-torch/blob/63da5d33a225c195fea84610e2456d5f722f3963/.test-cover.sh
|
# Source: https://github.com/uber/go-torch/blob/63da5d33a225c195fea84610e2456d5f722f3963/.test-cover.sh
|
||||||
CI=$1
|
|
||||||
echo "run for $CI"
|
|
||||||
|
|
||||||
if [ "$CI" == "circle-ci" ]; then
|
cd ${GOPATH}/src/github.com/${CIRCLE_PROJECT_USERNAME}/${CIRCLE_PROJECT_REPONAME}
|
||||||
cd ${GOPATH}/src/github.com/${CIRCLE_PROJECT_USERNAME}/${CIRCLE_PROJECT_REPONAME}
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "mode: count" > profile.cov
|
echo "mode: count" > profile.cov
|
||||||
FAIL=0
|
FAIL=0
|
||||||
|
@ -27,5 +23,5 @@ done
|
||||||
# Failures have incomplete results, so don't send
|
# Failures have incomplete results, so don't send
|
||||||
[ "$FAIL" -ne 0 ] && exit 1
|
[ "$FAIL" -ne 0 ] && exit 1
|
||||||
|
|
||||||
goveralls -service=$CI -v -coverprofile=profile.cov
|
goveralls -service=circle-ci -v -coverprofile=profile.cov
|
||||||
bash <(curl -s https://codecov.io/bash) -t $CODECOV_TOKEN -f profile.cov
|
bash <(curl -s https://codecov.io/bash) -t $CODECOV_TOKEN -f profile.cov
|
|
@ -22,10 +22,12 @@ jobs:
|
||||||
- run: dep ensure
|
- run: dep ensure
|
||||||
- run: go get github.com/mattn/goveralls
|
- run: go get github.com/mattn/goveralls
|
||||||
- run: go get golang.org/x/tools/cmd/cover
|
- run: go get golang.org/x/tools/cmd/cover
|
||||||
- run: ./.test-coverage circle-ci
|
- run: ./.circleci/check-coverage
|
||||||
- store_test_results:
|
- store_test_results:
|
||||||
path: ./
|
path: ./
|
||||||
destination: profile.cov
|
destination: profile.cov
|
||||||
|
- run: ./.circleci/check-gofmt
|
||||||
|
- run: ./.circleci/check-testfiles
|
||||||
test_race:
|
test_race:
|
||||||
docker:
|
docker:
|
||||||
- image: circleci/golang:latest
|
- image: circleci/golang:latest
|
16
.travis.yml
16
.travis.yml
|
@ -1,16 +0,0 @@
|
||||||
language: go
|
|
||||||
go:
|
|
||||||
- 1.9.x
|
|
||||||
- 1.10.x
|
|
||||||
install:
|
|
||||||
- curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
|
|
||||||
- dep ensure
|
|
||||||
- go get github.com/client9/misspell/cmd/misspell
|
|
||||||
- go get github.com/mattn/goveralls
|
|
||||||
- go get golang.org/x/tools/cmd/cover
|
|
||||||
script:
|
|
||||||
- ./.test-coverage travis-ci
|
|
||||||
- ./.test-testfiles
|
|
||||||
- ./.travis.gofmt.sh
|
|
||||||
- find . -type f -name '*.go' | grep -v '^./vendor/' | xargs misspell -error
|
|
||||||
- go install github.com/FreifunkBremen/yanic
|
|
|
@ -8,7 +8,6 @@ __ __ _
|
||||||
Yet another node info collector
|
Yet another node info collector
|
||||||
```
|
```
|
||||||
|
|
||||||
[![Build Status](https://travis-ci.org/FreifunkBremen/yanic.svg?branch=master)](https://travis-ci.org/FreifunkBremen/yanic)
|
|
||||||
[![CircleCI](https://circleci.com/gh/FreifunkBremen/yanic/tree/master.svg?style=shield)](https://circleci.com/gh/FreifunkBremen/yanic/tree/master)
|
[![CircleCI](https://circleci.com/gh/FreifunkBremen/yanic/tree/master.svg?style=shield)](https://circleci.com/gh/FreifunkBremen/yanic/tree/master)
|
||||||
[![Coverage Status](https://coveralls.io/repos/github/FreifunkBremen/yanic/badge.svg?branch=master)](https://coveralls.io/github/FreifunkBremen/yanic?branch=master)
|
[![Coverage Status](https://coveralls.io/repos/github/FreifunkBremen/yanic/badge.svg?branch=master)](https://coveralls.io/github/FreifunkBremen/yanic?branch=master)
|
||||||
[![codecov](https://codecov.io/gh/FreifunkBremen/yanic/branch/master/graph/badge.svg)](https://codecov.io/gh/FreifunkBremen/yanic)
|
[![codecov](https://codecov.io/gh/FreifunkBremen/yanic/branch/master/graph/badge.svg)](https://codecov.io/gh/FreifunkBremen/yanic)
|
||||||
|
|
Loading…
Reference in New Issue