Skip to content

Commit

Permalink
Checkout for coverage upload
Browse files Browse the repository at this point in the history
  • Loading branch information
vshampor committed Aug 16, 2023
1 parent 12b1e90 commit 4790fc2
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 16 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/post_pr_merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ jobs:
if: github.event.pull_request.merged == true
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3 # codecov uploader demands that the scanned files be present when uploading
with:
ref: ${{ github.event.pull_request.merge_commit_sha }}
- uses: dawidd6/action-download-artifact@v2
with:
workflow: precommit.yml
Expand All @@ -34,4 +37,4 @@ jobs:
# github.event.pull_request.merge_commit_sha is the fresh commit in the develop,
# provided that github.event.pull_request.merged == true
./codecov -f ./coverage.xml -t ${{ secrets.CODECOV_TOKEN }} -C ${{ github.event.pull_request.merge_commit_sha }} -B develop
./codecov -f ./coverage.xml -t ${{ secrets.CODECOV_TOKEN }} -C ${{ github.event.pull_request.merge_commit_sha }} -B develop -n "codecov-onnx"
35 changes: 20 additions & 15 deletions .github/workflows/precommit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,23 @@ jobs:
onnx:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
with:
lfs: true
- uses: actions/setup-python@v3
with:
python-version: 3.8.10
- name: Install NNCF and test requirements
run: make install-onnx-test
- name: Run ONNX precommit test scope
run: make test-onnx
- name: Upload coverage report as artifact
uses: actions/upload-artifact@v3
with:
name: coverage_xml # optional
path: ./coverage.xml
- uses: actions/checkout@v3
with:
lfs: true
- uses: actions/setup-python@v3
with:
python-version: 3.8.10
- name: Install NNCF and test requirements
run: make install-onnx-test
- name: Run ONNX precommit test scope
run: make test-onnx
- name: Upload coverage report as artifact
uses: actions/upload-artifact@v3
with:
name: coverage_xml # optional
path: ./coverage.xml
- name: Upload coverage report to codecov
uses: codecov/codecov-action
with:
token: ${{ secrets.CODECOV_TOKEN }}
name: codecov-onnx # optional

0 comments on commit 4790fc2

Please sign in to comment.