Skip to content

Commit

Permalink
ci: migrate to coveralls (#933)
Browse files Browse the repository at this point in the history
  • Loading branch information
sundowndev committed Nov 3, 2021
1 parent e46a515 commit a6e6aef
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
15 changes: 7 additions & 8 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,15 @@ jobs:
- name: Lint
run: |
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.24.0
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.43.0
./bin/golangci-lint run -D errcheck
- name: Test
run: go test -race -coverprofile=./c.out -covermode=atomic -v ./...

- name: Report code coverage
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
curl -s -o codecov https://codecov.io/bash \
&& VERSION=$(grep 'VERSION=\".*\"' codecov | cut -d'"' -f2) \
&& shasum -a 512 -c --ignore-missing <(curl -s https://raw.githubusercontent.com/codecov/codecov-bash/${VERSION}/SHA512SUM)
chmod +x codecov
go test -race -coverprofile=coverage.txt -covermode=atomic -v ./...
./codecov
go install github.com/mattn/goveralls@latest
goveralls -coverprofile=./c.out -service=github
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
<a href="https://codeclimate.com/github/sundowndev/phoneinfoga/maintainability">
<img src="https://api.codeclimate.com/v1/badges/3259feb1c68df1cd4f71/maintainability" />
</a>
<a href="https://codecov.io/gh/sundowndev/phoneinfoga">
<img src="https://codecov.io/gh/sundowndev/phoneinfoga/branch/master/graph/badge.svg" />
<a href='https://coveralls.io/github/sundowndev/phoneinfoga'>
<img src='https://coveralls.io/repos/github/sundowndev/phoneinfoga/badge.svg' alt='Coverage Status' />
</a>
<a href="https://github.com/sundowndev/phoneinfoga/releases">
<img src="https://img.shields.io/github/release/SundownDEV/phoneinfoga.svg" alt="Latest version" />
Expand Down

0 comments on commit a6e6aef

Please sign in to comment.