Upload coverage report from CI

This commit is contained in:
Eugenio Lacuesta 2020-12-16 18:16:48 -03:00
parent 3cb1dc63eb
commit fc5070ffda
No known key found for this signature in database
GPG Key ID: DA3EF2D0913E9810
2 changed files with 9 additions and 1 deletions

View File

@ -106,6 +106,7 @@ jobs:
tox
- name: Run check (ubuntu)
id: ubuntu-tests
if: startsWith(matrix.os, 'ubuntu')
env: ${{ matrix.env }}
run: |
@ -118,6 +119,13 @@ jobs:
fi
pip install -U tox
tox
if [ -f "coverage.xml" ]; then
echo ::set-output name=upload_coverage_report::true
fi
- name: Upload coverage report
if: steps.ubuntu-tests.outputs.upload_coverage_report == 'true'
run: bash <(curl -s https://codecov.io/bash)
publish:
name: "Publish package to PyPI"

View File

@ -27,7 +27,7 @@ passenv =
#allow tox virtualenv to upgrade pip/wheel/setuptools
download = true
commands =
py.test --cov=scrapy --cov-report= {posargs:--durations=10 docs scrapy tests}
py.test --cov=scrapy --cov-report=xml --cov-report= {posargs:--durations=10 docs scrapy tests}
[testenv:typing]
basepython = python3