Merge pull request #1060 from kivy/feature/coverage_testing

Setup coverage testing, closes #1058
This commit is contained in:
Andre Miras 2020-04-10 16:31:18 +02:00 committed by GitHub
commit 21d4157573
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 1 deletions

View file

@ -25,7 +25,7 @@ jobs:
- name: Requirements
run: |
pip install --timeout=120 -U setuptools tox>=2.0
pip install -U coveralls setuptools tox>=2.0
tox
- name: Build
run: |
@ -33,3 +33,7 @@ jobs:
- name: Test
run: |
docker run buildozer --version
- name: coveralls
run: coveralls
env:
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}

View file

@ -2,6 +2,7 @@ Buildozer
=========
[![Build](https://github.com/kivy/buildozer/workflows/Continuous%20Integration/badge.svg)](https://github.com/kivy/buildozer/actions?query=workflow%3A%22Continuous+Integration%22)
[![Coverage Status](https://coveralls.io/repos/github/kivy/buildozer/badge.svg)](https://coveralls.io/github/kivy/buildozer)
[![Backers on Open Collective](https://opencollective.com/kivy/backers/badge.svg)](#backers)
[![Sponsors on Open Collective](https://opencollective.com/kivy/sponsors/badge.svg)](#sponsors)

View file

@ -5,8 +5,15 @@ envlist = pep8,py27,py3
deps =
mock
pytest
py3: coverage
commands = pytest tests/
[testenv:py3]
# for py3 env we will get code coverage
commands =
coverage run --branch --source=buildozer -m pytest {posargs:tests/}
coverage report -m
[testenv:pep8]
deps = flake8
commands = flake8 buildozer/