Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Codecov: collect test analytics #1281

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 16 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,26 @@ jobs:
run: |
docker compose -p cms -f docker-compose.test.yml run --rm testcms

- uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Upload test results to Codecov
if: ${{ !cancelled() }}
uses: codecov/test-results-action@v1
with:
files: ./codecov/junit.xml
flags: unittests
token: ${{ secrets.CODECOV_TOKEN }}

- name: Upload unit test coverage results to Codecov
uses: codecov/codecov-action@v4
if: ${{ !cancelled() }}
with:
files: ./codecov/unittests.xml
flags: unittests
token: ${{ secrets.CODECOV_TOKEN }}

- uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Upload functional test coverage results to Codecov
uses: codecov/codecov-action@v4
if: ${{ !cancelled() }}
with:
files: ./codecov/functionaltests.xml
flags: functionaltests
token: ${{ secrets.CODECOV_TOKEN }}
2 changes: 1 addition & 1 deletion _cms-test-internal.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ dropdb --host=testdb --username=postgres cmsdbfortesting
createdb --host=testdb --username=postgres cmsdbfortesting
cmsInitDB

pytest --cov . --cov-report xml:codecov/unittests.xml
pytest --cov . --cov-report xml:codecov/unittests.xml --junitxml=codecov/junit.xml -o junit_family=legacy
UNIT=$?

dropdb --host=testdb --username=postgres cmsdbfortesting
Expand Down
Loading