Skip to content

Commit

Permalink
Test codecov upload
Browse files Browse the repository at this point in the history
  • Loading branch information
AlbumenJ committed Dec 1, 2024
1 parent 21f5e1d commit ebd321e
Showing 1 changed file with 11 additions and 12 deletions.
23 changes: 11 additions & 12 deletions .github/workflows/build-and-test-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -255,11 +255,14 @@ jobs:
- name: "Print test error log"
if: failure()
run: cat test_errors.log
- name: "Upload coverage result"
uses: actions/upload-artifact@v4
- name: "Upload coverage to Codecov"
uses: codecov/codecov-action@v4
with:
name: coverage-result
path: "**/target/site/**/jacoco.xml"
token: ${{ secrets.CODECOV_TOKEN }}
version: v0.6.0
verbose: true
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

samples-test-prepare:
needs: check-format
Expand Down Expand Up @@ -469,7 +472,7 @@ jobs:

jacoco-result-merge:
runs-on: ubuntu-latest
needs: [check-format, integration-test-result, samples-test-result, unit-test]
needs: [check-format, integration-test-result, samples-test-result]
steps:
- uses: actions/checkout@v4
with:
Expand Down Expand Up @@ -517,18 +520,14 @@ jobs:
run: |
cd ${{ github.workspace }}/dubbo-integration-cases/test/dubbo-test-jacoco-merger
mvn clean compile exec:java -Dexec.mainClass="org.apache.dubbo.test.JacocoReport" -Dexec.args="${{github.workspace}}/dubbo-integration-cases ${{github.workspace}}/dubbo"
- name: "Restore coverage result"
uses: actions/download-artifact@v4
with:
name: coverage-result
github-token: ${{ secrets.GITHUB_TOKEN }}
path: dubbo/
- name: "Upload coverage to Codecov"
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
version: v0.6.0
verbose: true
root_dir: ${{ github.workspace }}/dubbo
working-directory: ${{ github.workspace }}/dubbo
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

Expand Down

0 comments on commit ebd321e

Please sign in to comment.