Skip to content

Commit

Permalink
Support current python versions and add coverage. (#22)
Browse files Browse the repository at this point in the history
* Support current python versions and add coverage
  • Loading branch information
sallner committed Oct 26, 2018
1 parent 541893b commit 2f38dd2
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 25 deletions.
2 changes: 1 addition & 1 deletion .coveragerc
@@ -1,6 +1,6 @@
[run]
source = $COVERAGE_HOME/src/zdaemon
omit = */tests/*, */__main__.py
omit = */__main__.py
parallel = true
data_file = $COVERAGE_HOME/.coverage

Expand Down
24 changes: 18 additions & 6 deletions .travis.yml
Expand Up @@ -2,16 +2,28 @@ language: python
sudo: false
python:
- 2.7
- 3.3
- 3.4
- 3.5
- 3.6
- pypy
# PyPy3 support pending a release of a fix for
# https://bitbucket.org/pypy/pypy/issue/1946)
# - pypy3
- pypy3
matrix:
include:
- python: "3.7"
dist: xenial
sudo: true
install:
- pip install .
- pip install -U pip setuptools
- pip install -U coverage coveralls
- pip install -U -e .[test]
script:
- python setup.py -q test -q
- export COVERAGE_HOME=$(pwd)
- export COVERAGE_PROCESS_START=$COVERAGE_HOME/.coveragerc
- coverage run -m zope.testrunner --test-path=src
- coverage combine
after_success:
- coveralls
notifications:
email: false
cache: pip

6 changes: 4 additions & 2 deletions CHANGES.rst
Expand Up @@ -2,10 +2,12 @@
Change log
==========

4.2.1 (unreleased)
4.3.0 (unreleased)
==================

- Nothing changed yet.
- Add support for Python 3.6 and 3.7.

- Drop support for Python 3.3.


4.2.0 (2016-12-07)
Expand Down
5 changes: 3 additions & 2 deletions setup.py
Expand Up @@ -57,7 +57,7 @@ def alltests():

setup(
name="zdaemon",
version='4.2.1.dev0',
version='4.3.0.dev0',
url="https://github.com/zopefoundation/zdaemon",
license="ZPL 2.1",
description=
Expand All @@ -81,9 +81,10 @@ def alltests():
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy',
'Operating System :: POSIX',
Expand Down
20 changes: 6 additions & 14 deletions tox.ini
@@ -1,31 +1,23 @@
[tox]
# PyPy3 support pending a release of a fix for
# https://bitbucket.org/pypy/pypy/issue/1946)
#envlist = py27,py33,py34,pypy,pypy3
envlist = py27,py33,py34,py35,pypy
envlist = py27,py34,py35,py36,py37,pypy,pypy3,coverage

[testenv]
commands =
python setup.py -q test -q
# without explicit deps, setup.py test will download a bunch of eggs into $PWD
zope-testrunner --test-path=src []
deps =
zc.customdoctests
zope.testing
zope.testrunner
manuel
mock
.[test]

[testenv:coverage]
usedevelop = true
basepython =
python2.7
python3.6
setenv =
COVERAGE_HOME={toxinidir}
COVERAGE_PROCESS_START={toxinidir}/.coveragerc
commands =
coverage run --source=zdaemon setup.py -q test
coverage run -m zope.testrunner --test-path=src []
coverage combine
coverage report
coverage report --fail-under=83
deps =
{[testenv]deps}
coverage

0 comments on commit 2f38dd2

Please sign in to comment.