Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests: fix pytest 6.x coverage #130

Merged
merged 3 commits into from
Oct 27, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
[run]
source = luma.lcd
omit =
luma/__init__.py
setup.py
.tox/*
doc/*
2 changes: 1 addition & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include README.rst CHANGES.rst CONTRIBUTING.rst LICENSE.rst tox.ini setup.cfg .coveragerc
include README.rst CHANGES.rst CONTRIBUTING.rst LICENSE.rst tox.ini setup.cfg pytest.ini .coveragerc

recursive-include luma *.py

Expand Down
2 changes: 1 addition & 1 deletion doc/install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Finally, you need to leverage the appropriate interface class and display
class for your device to implement your application. Instructions for that
are included in :doc:`python-usage`.

.. note:: This library has been tested against Python 3.5, 3.6, 3.7 and 3.8.
.. note:: This library has been tested against Python 3.6 and newer.

It was *originally* tested with Raspbian on a rev.2 model B, with a vanilla
kernel version 4.1.16+, and has subsequently been tested on Raspberry Pi
Expand Down
3 changes: 3 additions & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[pytest]
addopts = --timeout=10 -v -r wsx

2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def find_version(*file_paths):
needs_pytest = {'pytest', 'test', 'ptr'}.intersection(sys.argv)
pytest_runner = ['pytest-runner'] if needs_pytest else []
test_deps = [
'pytest<=4.5',
'pytest',
'pytest-cov',
'pytest-timeout'
]
Expand Down
5 changes: 3 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,11 @@ envlist = py{36,37,38,39},qa,doc
skip_missing_interpreters = True

[testenv]
usedevelop = true
commands =
python setup.py install
coverage run -m py.test --timeout=10 -v -r w
coverage report
pytest --cov=luma
coverage html
deps = .[test]

[testenv:qa]
Expand Down