aboutsummaryrefslogtreecommitdiffstats
path: root/tox.ini
diff options
context:
space:
mode:
authorMaximilian Hils <git@maximilianhils.com>2016-06-28 19:44:25 -0700
committerMaximilian Hils <git@maximilianhils.com>2016-06-28 19:44:25 -0700
commitf69972d13d9c6bfc5f59e71c1253b8d81003d064 (patch)
tree792adf802d32544065c1566cbc86930eb40aa808 /tox.ini
parent3b53d3e393f30879420b4407583c42bb1f51563e (diff)
downloadmitmproxy-f69972d13d9c6bfc5f59e71c1253b8d81003d064.tar.gz
mitmproxy-f69972d13d9c6bfc5f59e71c1253b8d81003d064.tar.bz2
mitmproxy-f69972d13d9c6bfc5f59e71c1253b8d81003d064.zip
simplify tox setup
Diffstat (limited to 'tox.ini')
-rw-r--r--tox.ini45
1 files changed, 11 insertions, 34 deletions
diff --git a/tox.ini b/tox.ini
index 13b67ad5..38507f27 100644
--- a/tox.ini
+++ b/tox.ini
@@ -2,52 +2,29 @@
envlist = py27, py35, docs, lint
[testenv]
+usedevelop=True
deps =
+ {env:CI_DEPS:}
-rrequirements.txt
- codecov>=2.0.5
-passenv = USERNAME HOME HOMEPATH LOCALAPPDATA CODECOV_TOKEN CI TRAVIS TRAVIS_* APPVEYOR APPVEYOR_*
+passenv = CODECOV_TOKEN CI CI_* TRAVIS TRAVIS_* APPVEYOR APPVEYOR_*
setenv =
- PY3TESTS = test/netlib test/pathod/ test/mitmproxy/script test/mitmproxy/test_contentview.py test/mitmproxy/test_custom_contentview.py test/mitmproxy/test_app.py test/mitmproxy/test_controller.py test/mitmproxy/test_fuzzing.py test/mitmproxy/test_script.py test/mitmproxy/test_web_app.py test/mitmproxy/test_utils.py test/mitmproxy/test_stateobject.py test/mitmproxy/test_cmdline.py test/mitmproxy/test_contrib_tnetstring.py test/mitmproxy/test_proxy.py test/mitmproxy/test_protocol_http1.py test/mitmproxy/test_platform_pf.py
-
-[testenv:py27]
+ TESTS = test/
+ HOME = {envtmpdir}
commands =
- py.test -n 8 --timeout 60 []
+ py.test -n 4 --timeout 60 {posargs} {env:TESTS}
+ {env:CI_COMMANDS:python -c ""}
[testenv:py35]
-# remove bash & pipe & grep hack after cryptography ships with openssl 1.1.0
-whitelist_externals = bash
-commands =
- bash -c 'set -o pipefail ; py.test -n 8 --timeout 60 {env:PY3TESTS:} 2>&1 | grep -v Cryptography_locking_cb'
-
-[testenv:py27-ci]
-commands =
- py.test --cov netlib --cov mitmproxy --cov pathod --timeout 60
- codecov -e TOXENV
-
-[testenv:py35-ci]
-# remove bash & pipe & grep hack after cryptography ships with openssl 1.1.0
-whitelist_externals = bash
-commands =
- bash -c 'set -o pipefail ; py.test --cov netlib --cov mitmproxy --cov pathod --timeout 60 {env:PY3TESTS:} 2>&1 | grep -v Cryptography_locking_cb'
- codecov -e TOXENV
-
-[testenv:py35-ci-win]
-deps =
- https://snapshots.mitmproxy.org/misc/lxml-3.6.0-cp35-cp35m-win32.whl
- codecov>=2.0.5
- .[dev]
-commands =
- py.test --cov netlib --cov mitmproxy --cov pathod --timeout 60 {env:PY3TESTS:}
- codecov -e TOXENV
+setenv =
+ TESTS = test/netlib test/pathod/ test/mitmproxy/script test/mitmproxy/test_contentview.py test/mitmproxy/test_custom_contentview.py test/mitmproxy/test_app.py test/mitmproxy/test_controller.py test/mitmproxy/test_fuzzing.py test/mitmproxy/test_script.py test/mitmproxy/test_web_app.py test/mitmproxy/test_utils.py test/mitmproxy/test_stateobject.py test/mitmproxy/test_cmdline.py test/mitmproxy/test_contrib_tnetstring.py test/mitmproxy/test_proxy.py test/mitmproxy/test_protocol_http1.py test/mitmproxy/test_platform_pf.py
[testenv:docs]
basepython = python2.7
whitelist_externals = make
changedir = docs
-setenv = SPHINXOPTS="-W"
-commands = make -e html
+commands = sphinx-build -W -b html -d {envtmpdir}/doctrees . {envtmpdir}/html
[testenv:lint]
-basepython = python2.7
+basepython = python
deps = flake8>=2.6.2, <3
commands = flake8 --jobs 8 --count mitmproxy netlib pathod examples test