ci: Migrate to new Codecov uploader.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
Anders Kaseorg 2021-10-13 14:25:36 -07:00 committed by Anders Kaseorg
parent d312432ea8
commit 9cf5a03f2a
2 changed files with 4 additions and 7 deletions

View File

@ -200,13 +200,9 @@ jobs:
# Only upload coverage when both frontend and backend
# tests are ran.
if: ${{ matrix.include_frontend_tests }}
run: |
# Codcov requires `.coverage` file to be stored in the
# current working directory.
mv ./var/.coverage ./.coverage
. /srv/zulip-py3-venv/bin/activate || true
pip install codecov && codecov || echo "Error in uploading coverage reports to codecov.io."
uses: codecov/codecov-action@v2
with:
files: var/coverage.xml,var/node-coverage/lcov.info
- name: Store Puppeteer artifacts
# Upload these on failure, as well

View File

@ -441,6 +441,7 @@ def main() -> None:
if options.verbose_coverage:
print("Printing coverage data")
cov.report(show_missing=False)
cov.xml_report(outfile="var/coverage.xml")
cov.html_report(directory="var/coverage")
print("HTML report saved; visit at http://127.0.0.1:9991/coverage/index.html")
if full_suite and not failures and options.coverage: