diff --git a/.github/workflows/hypothesis.yml b/.github/workflows/hypothesis.yml index 3c647a7852..1776f03683 100644 --- a/.github/workflows/hypothesis.yml +++ b/.github/workflows/hypothesis.yml @@ -27,3 +27,10 @@ jobs: - name: Run Hypothesis tests run: tox -e hypothesis,coverage + + - name: Upload Python coverage to codecov + uses: codecov/codecov-action@v3 + with: + flags: hypothesis-py + fail_ci_if_error: true + files: .tox/coverage.xml diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 139147dfe1..42ec66bef6 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -73,3 +73,10 @@ jobs: run: tox env: PYTHONDEVMODE: 1 + + - name: Upload Python coverage to codecov + uses: codecov/codecov-action@v3 + with: + flags: python + fail_ci_if_error: true + files: .tox/coverage.xml diff --git a/tox.ini b/tox.ini index 4fae4cc6ff..f3ac6412d7 100644 --- a/tox.ini +++ b/tox.ini @@ -4,7 +4,6 @@ envlist = py311, py39, coverage, - codecov, docs, package_description py38, @@ -161,22 +160,6 @@ commands = coverage combine depends = py39, py38, py37, pypy3 parallel_show_output = True -[testenv:codecov] -description = [only run on CI]: upload coverage data to codecov (depends on coverage running first) -passenv = {[testenv]passenv} - CODECOV_* - GITHUB_ACTION - GITHUB_REF - GITHUB_HEAD_REF - GITHUB_RUN_ID - GITHUB_SHA - GITHUB_REPOSITORY -deps = codecov -skip_install = True -changedir = {toxinidir} -depends = coverage -commands = codecov -e $TOXENV --file "{toxworkdir}/coverage.xml" -F python {posargs} - [testenv:X] description = print the positional arguments passed in with echo commands = echo {posargs} @@ -209,10 +192,10 @@ source = src/sourmash/ [gh-actions] python = - 3.10: py310, docs, package_description, coverage, codecov - 3.11: py311, coverage, codecov - 3.9: py39, coverage, codecov - 3.8: py38, coverage, codecov + 3.10: py310, docs, package_description, coverage + 3.11: py311, coverage + 3.9: py39, coverage + 3.8: py38, coverage [flake8] max-complexity = 22