summaryrefslogtreecommitdiff
path: root/tox.ini
diff options
context:
space:
mode:
authorDana Powers <dana.powers@rd.io>2016-01-01 15:04:51 -0800
committerDana Powers <dana.powers@rd.io>2016-01-01 22:44:19 -0800
commit1a6ff2615cebde0dab49151b4b8a15fc97edb4e6 (patch)
tree517ab0ebb631a3b4a7f15b3b223b3dabd8525fa8 /tox.ini
parentcb325af5ffc3f711842e103130a87d5b073a9ff5 (diff)
downloadkafka-python-1a6ff2615cebde0dab49151b4b8a15fc97edb4e6.tar.gz
Use pytest instead of nose for running tests via tox
- use pytest-sugar for pretty output - add linting to each python tox environment - drop lint as separate tox target - replace travis_selector.sh with shell magic
Diffstat (limited to 'tox.ini')
-rw-r--r--tox.ini43
1 files changed, 9 insertions, 34 deletions
diff --git a/tox.ini b/tox.ini
index 1ee1e16..b00d531 100644
--- a/tox.ini
+++ b/tox.ini
@@ -1,48 +1,23 @@
[tox]
-envlist = lint, py26, py27, pypy, py33, py34, py35, docs
+envlist = py{26,27,py,33,34,35}, docs
[testenv]
deps =
- nose
- nose-timer
- coverage
+ pytest
+ pytest-cov
+ pytest-catchlog
+ pytest-pylint
+ pytest-sugar
mock
python-snappy
+ py{26,27}: six
+ py26: unittest2
commands =
- nosetests {posargs:-v -x --with-id --id-file={envdir}/.noseids --with-timer --timer-top-n 10 --with-coverage --cover-erase --cover-package kafka}
+ py.test {posargs:--pylint --pylint-rcfile=pylint.rc --pylint-error-types=EF --durations=10 --cov=kafka --doctest-modules kafka test}
setenv =
- NOSE_LOGFORMAT = %(asctime)s - %(thread)d - %(name)s - %(levelname)s - %(message)s
PROJECT_ROOT = {toxinidir}
passenv = KAFKA_VERSION
-[testenv:py26]
-deps =
- six
- unittest2
- nose
- nose-timer
- coverage
- mock
- python-snappy
-
-[testenv:py27]
-deps =
- six
- unittest2
- nose
- nose-timer
- coverage
- mock
- python-snappy
-
-[testenv:lint]
-basepython = python2.7
-deps =
- unittest2
- mock
- pylint
-commands = pylint --rcfile=pylint.rc {posargs: -E kafka test}
-
[testenv:docs]
deps =
sphinxcontrib-napoleon