Skip to content

Commit

Permalink
enable code coverage (IceWhaleTech#825)
Browse files Browse the repository at this point in the history
  • Loading branch information
tigerinus authored Jan 16, 2023
1 parent 86380d9 commit fcfb48d
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Collect Code Coverage

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Run coverage
run: go test -race -failfast -coverprofile=coverage.txt -covermode=atomic -v ./...
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@
<a href="https://github.com/IceWhaleTech/CasaOS/issues" target="_blank">
<img alt="CasaOS Issues" src="https://img.shields.io/github/issues/IceWhaleTech/CasaOS?color=162453&style=flat-square&label=Issues" />
</a>
<a href="https://codecov.io/gh/IceWhaleTech/CasaOS" >
<img src="https://codecov.io/gh/IceWhaleTech/CasaOS/branch/main/graph/badge.svg?token=l9uMKGlkxM"/>
</a>
<a href="https://github.com/IceWhaleTech/CasaOS/stargazers" target="_blank">
<img alt="CasaOS Stargazers" src="https://img.shields.io/github/stars/IceWhaleTech/CasaOS?color=162453&style=flat-square&label=Stars" />
</a>
Expand Down

0 comments on commit fcfb48d

Please sign in to comment.