Skip to content

Commit

Permalink
coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
ErnestaP committed Mar 5, 2024
1 parent bead027 commit f3b1d30
Showing 1 changed file with 17 additions and 4 deletions.
21 changes: 17 additions & 4 deletions .github/workflows/run-pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,23 @@ jobs:
username: ${{ secrets.HARBOR_USERNAME }}
password: ${{ secrets.HARBOR_PASSWORD }}

- name: Run tests with pytest
- name: Run tests with pytest and generate report
run: >
docker run
--name cern-sis/biproject
--name biproject
--network=host
-v "$(pwd)"/cern-sis/biproject:/opt/airflow/tests
--entrypoint pytest cern-sis/biproject /opt/airflow/tests
-v "$(pwd)"/tests:/opt/airflow/tests
-v "$(pwd)"/data:/opt/airflow/data
--entrypoint pytest
$REGISTRY/$IMAGE@${{ steps.build.outputs.image-digest }}
tests
--cov=./
--cov-report=xml
- name: Copy test coverage file to host machine
run: docker cp biproject:/opt/airflow/coverage.xml .

- name: Upload Coverage to Codecov
uses: codecov/codecov-action@v3
with:
verbose: true

0 comments on commit f3b1d30

Please sign in to comment.