Skip to content

Commit

Permalink
ci: fix coverage upload (project-stacker#637)
Browse files Browse the repository at this point in the history
Ensure that the coverage upload token is passed correctly.

Signed-off-by: Ramkumar Chinchani <[email protected]>
  • Loading branch information
rchincha authored Aug 28, 2024
1 parent f52ce15 commit 4cb72cf
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ on:
type: boolean
description: 'Should slow tests be run?'
default: true
secrets:
codecov_token:
required: true

jobs:
build:
Expand Down Expand Up @@ -100,7 +103,7 @@ jobs:
- name: Upload code coverage
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
token: ${{ secrets.codecov_token }}
- name: Upload artifacts
uses: actions/upload-artifact@v3
if: ${{ matrix.privilege-level == 'priv' }}
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,11 @@ jobs:
uses: ./.github/workflows/build.yaml
with:
slow-test: false
secrets:
codecov_token: ${{ secrets.CODECOV_TOKEN }}
coverage:
uses: ./.github/workflows/coverage.yaml
with:
slow-test: false
secrets:
codecov_token: ${{ secrets.CODECOV_TOKEN }}
5 changes: 4 additions & 1 deletion .github/workflows/coverage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ on:
type: boolean
description: 'Should slow tests be run?'
default: true
secrets:
codecov_token:
required: true

jobs:
build:
Expand Down Expand Up @@ -97,7 +100,7 @@ jobs:
- name: Upload code coverage
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
token: ${{ secrets.codecov_token }}
files: coverage-${{ matrix.privilege-level}}.txt
- name: Upload artifacts
uses: actions/upload-artifact@v3
Expand Down

0 comments on commit 4cb72cf

Please sign in to comment.