Skip to content

ci: bump codecov/codecov-action (#19) #63

ci: bump codecov/codecov-action (#19)

ci: bump codecov/codecov-action (#19) #63

Workflow file for this run

name: "Code Coverage"
on:
push:
branches: master
paths:
- ".github/workflows/coverage.yml"
- "tests/unit/*.go"
pull_request:
branches: master
jobs:
code-coverage:
name: Codecov
runs-on: ubuntu-latest
if: |
github.actor != 'dependabot[bot]' &&
github.actor != 'github-actions[bot]' &&
github.actor != 'protected-auto-commits[bot]'
permissions:
contents: read
pull-requests: write
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: "1.23.x"
- name: Install Dependencies
run: go mod tidy
- name: Run tests with coverage
run: |
go test -coverprofile=coverage.txt -covermode=atomic -coverpkg=./pkg/... ./tests/unit/...
- name: Upload coverage to Codecov
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.txt
flags: unittests
name: codecov-umbrella
fail_ci_if_error: true