Skip to content

Commit

Permalink
generate backend html coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
juancwu committed Nov 26, 2024
1 parent 9c2fecf commit 043e3f5
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/test-backend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@ jobs:
# run tests and capture output
cd backend
go test -v -coverprofile=coverage.out ./...
# - name: Generate coverage report
# run: cd backend && go tool cover -html=coverage.out -o coverage.html
# - name: Upload coverage report
# if: ${{ !env.ACT && github.event_name == 'pull_request' }}
# uses: actions/upload-artifact@v4
# with:
# name: coverage-report-backend
# path: backend/coverage.html
- name: Generate coverage report
run: cd backend && go tool cover -html=coverage.out -o coverage.html
- name: Upload coverage report
if: ${{ !env.ACT && github.event_name == 'pull_request' }}
uses: actions/upload-artifact@v4
with:
name: coverage-report-backend
path: backend/coverage.html
- name: Comment PR
if: ${{ !env.ACT && github.event_name == 'pull_request' && always() }}
uses: actions/github-script@v7
Expand Down

0 comments on commit 043e3f5

Please sign in to comment.