Skip to content

Commit

Permalink
Use CODECOV_TOKEN if available (#1073)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlekSi committed Aug 25, 2022
1 parent 4a950e3 commit eb9acfa
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,12 @@ jobs:
- name: Run unit tests
run: bin/task test-unit

# The token is not required but should make uploads more stable.
# If secrets are unavailable (for example, for a pull request from a fork), it fallbacks to the tokenless uploads.
- name: Upload coverage information
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./cover.txt
flags: unit
fail_ci_if_error: true
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,12 @@ jobs:
- name: Run ${{ matrix.handler }} tests
run: bin/task test-integration-${{ matrix.handler }}

# The token is not required but should make uploads more stable.
# If secrets are unavailable (for example, for a pull request from a fork), it fallbacks to the tokenless uploads.
- name: Upload coverage information
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./integration/integration-${{ matrix.handler }}.txt
flags: integration,${{ matrix.handler }}
fail_ci_if_error: true
Expand Down

0 comments on commit eb9acfa

Please sign in to comment.