Add coverage workflow

main v0.1.0
Gabe Farrell 2 years ago
parent 09e816b58a
commit 39eee32cfb

@ -0,0 +1,21 @@
on:
push:
branches:
- main
jobs:
coverage:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
- name: generate test coverage
run: go test ./... -coverprofile=./cover.out -covermode=atomic -coverpkg=./...
- name: check test coverage
uses: vladopajic/go-test-coverage@v2
with:
profile: cover.out
local-prefix: github.com/gabehf/go-elo
git-token: ${{ github.ref_name == 'main' && secrets.GITHUB_TOKEN || '' }}
git-branch: badges

@ -1,5 +1,7 @@
# go-elo: A flexible elo calculator for Go
![coverage](https://raw.githubusercontent.com/gabehf/go-elo/badges/.badges/main/coverage.svg)
This package allows you to add flexible elo/skill tracking to your application.
Go-elo supports unscored (win/loss) and scored matches, with options to tailor the elo curve to your liking.

Loading…
Cancel
Save