Skip to content

Commit

Permalink
Add code coverage GH action
Browse files Browse the repository at this point in the history
  • Loading branch information
Victor Morales committed Feb 5, 2025
1 parent 40abec1 commit b6d9ca9
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,20 @@ jobs:
filters: |
golang:
- '**.go'
code-coverage:
name: Check code coverage
if: needs.changes.outputs.golang == 'true'
needs: changes
runs-on: ubuntu-latest
permissions:
contents: write
issues: write
pull-requests: write
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # 4.2.2
- uses: gwatts/go-coverage-action@2845595538a59d63d1bf55f109c14e104c6f7cb3 # 2.0.0
with:
coverage-threshold: 40
unit-test:
name: Check Go lang unit tests
if: needs.changes.outputs.golang == 'true'
Expand Down Expand Up @@ -77,7 +91,7 @@ jobs:
contents: read
attestations: write
id-token: write
needs: unit-test
needs: [code-coverage, unit-test]
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # 4.2.2
- name: Log in to the Container registry
Expand Down

0 comments on commit b6d9ca9

Please sign in to comment.