Skip to content

Commit

Permalink
ci: fix upload order
Browse files Browse the repository at this point in the history
Uploading artifacts before code coverage appears to impact coverage
stats. Perhaps there is a cleanup involved. So do it after.

Signed-off-by: Ramkumar Chinchani <[email protected]>
  • Loading branch information
rchincha committed Nov 20, 2023
1 parent cd153e6 commit 6afbd0d
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 15 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -84,14 +84,6 @@ jobs:
REGISTRY_URL: localhost:5000
ZOT_HOST: localhost
ZOT_PORT: 8080
- name: Upload artifacts
uses: actions/upload-artifact@v3
if: ${{ matrix.privilege-level == 'priv' }}
with:
# if there is more than 1 go-version, we would need to account for that here.
name: binary
path: stacker
if-no-files-found: error
- name: Show disk usage before running the tests
if: always()
uses: ./.github/actions/show-disk-usage
Expand All @@ -107,6 +99,14 @@ jobs:
uses: ./.github/actions/show-disk-usage
- name: Upload code coverage
uses: codecov/codecov-action@v3
- name: Upload artifacts
uses: actions/upload-artifact@v3
if: ${{ matrix.privilege-level == 'priv' }}
with:
# if there is more than 1 go-version, we would need to account for that here.
name: binary
path: stacker
if-no-files-found: error
- uses: actions/cache@v3
id: restore-build
with:
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/coverage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,13 @@ jobs:
REGISTRY_URL: localhost:5000
ZOT_HOST: localhost
ZOT_PORT: 8080
- name: Show disk usage after running the tests
if: always()
uses: ./.github/actions/show-disk-usage
- name: Upload code coverage
uses: codecov/codecov-action@v3
with:
files: coverage-${{ matrix.privilege-level}}.txt
- name: Upload artifacts
uses: actions/upload-artifact@v3
if: ${{ matrix.privilege-level == 'priv' }}
Expand All @@ -99,13 +106,6 @@ jobs:
name: binary-cov
path: stacker
if-no-files-found: error
- name: Show disk usage after running the tests
if: always()
uses: ./.github/actions/show-disk-usage
- name: Upload code coverage
uses: codecov/codecov-action@v3
with:
files: coverage-${{ matrix.privilege-level}}.txt
- uses: actions/cache@v3
id: restore-build
with:
Expand Down

0 comments on commit 6afbd0d

Please sign in to comment.