From 21951a41a45dd0587a46567b6c938cd7c4da9057 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Santiago=20Fraire=20Willemo=C3=ABs?= Date: Mon, 18 Nov 2019 13:17:47 +0100 Subject: [PATCH] ci: codeconv for github actions --- .github/workflows/pythonpackage.yml | 8 ++++++++ README.rst | 6 +++--- scripts/test | 2 +- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pythonpackage.yml b/.github/workflows/pythonpackage.yml index 3f794d3b20..467ef751c5 100644 --- a/.github/workflows/pythonpackage.yml +++ b/.github/workflows/pythonpackage.yml @@ -25,3 +25,11 @@ jobs: - name: Run tests run: | ./scripts/test + - name: Upload coverage to Codecov + if: runner.os == 'Linux' + uses: codecov/codecov-action@v1.0.3 + with: + token: ${{secrets.CODECOV_TOKEN}} + file: ./coverage.xml + flags: unittests + name: codecov-umbrella diff --git a/README.rst b/README.rst index 6f0ca4dd6e..acedde15fd 100644 --- a/README.rst +++ b/README.rst @@ -5,9 +5,9 @@ Commitizen Python 3 command line utility to standardize commit messages and bump version -.. image:: https://img.shields.io/travis/Woile/commitizen.svg?style=flat-square - :alt: Travis - :target: https://travis-ci.org/Woile/commitizen +.. image:: https://github.com/Woile/commitizen/workflows/Python%20package/badge.svg + :alt: Github Actions + :target: https://github.com/Woile/commitizen/actions .. image:: https://img.shields.io/badge/Conventional%20Commits-1.0.0-yellow.svg?style=flat-square :alt: Conventional Commits diff --git a/scripts/test b/scripts/test index 5984a5d4ee..2234ddc65c 100755 --- a/scripts/test +++ b/scripts/test @@ -3,6 +3,6 @@ if [ -d 'venv' ] ; then export PREFIX="venv/bin/" fi -${PREFIX}pytest --cov-report term-missing --cov=commitizen tests/ +${PREFIX}pytest --cov-report term-missing --cov-report=xml:coverage.xml --cov=commitizen tests/ ${PREFIX}black commitizen tests --check ${PREFIX}flake8 --max-line-length=88 commitizen/ tests/