summaryrefslogtreecommitdiffstats
path: root/tox.ini
diff options
context:
space:
mode:
authorYujun Zhang <zhang.yujunz@zte.com.cn>2017-11-29 16:40:39 +0800
committerYujun Zhang <zhang.yujunz@zte.com.cn>2017-12-04 11:12:27 -0800
commitf7882526b299e0e9185b1f61d3306b48d9ec28e6 (patch)
tree990921bee916d3553661b6656c247717b42c5c91 /tox.ini
parent795221ce0cbd9daf23af9f3099e29c947bcad306 (diff)
Use pipenv instead of pip
pipenv[1] is the officially recommended Python packaging tool from Python.org[2] [1]: https://docs.pipenv.org/ [2]: https://packaging.python.org/new-tutorials/installing-and-using-packages/ It integrates pip with virtualenv and handles version management better than pip. Change-Id: I4ec6436e29d76a866b56caa609e2bcd22489ae9f Signed-off-by: Yujun Zhang <zhang.yujunz@zte.com.cn>
Diffstat (limited to 'tox.ini')
-rw-r--r--tox.ini36
1 files changed, 14 insertions, 22 deletions
diff --git a/tox.ini b/tox.ini
index e5fe6e4e..37594bd6 100644
--- a/tox.ini
+++ b/tox.ini
@@ -9,20 +9,19 @@ skipsdist = True
[testenv]
usedevelop = True
-install_command = pip install -U {opts} {packages}
deps =
- -rrequirements.txt
- -rrequirements-test.txt
-commands=
- py.test \
- --basetemp={envtmpdir} \
- --cov \
- --cov-report term-missing \
- --cov-report xml \
- {posargs}
-setenv=
- HOME = {envtmpdir}
- PYTHONPATH = {toxinidir}
+ pipenv
+commands =
+ pipenv install --dev
+ py.test \
+ --basetemp={envtmpdir} \
+ --cov \
+ --cov-report term-missing \
+ --cov-report xml \
+ {posargs}
+setenv =
+ HOME = {envtmpdir}
+ PYTHONPATH = {toxinidir}
[testenv:pep8]
deps = flake8
@@ -37,19 +36,12 @@ ignore = E123,E125,H803,E501
builtins = _
exclude = build,dist,doc,legacy,.eggs,.git,.tox,.venv
-[testenv:reqs]
-deps=-rrequirements-test.txt
-commands=
- pip-missing-reqs qtip
- pip-extra-reqs qtip
- pipreqs qtip --savepath requirements-frozen.txt
-
[pytest]
testpaths = tests
python_functions = *_test test_*
[testenv:pip]
-deps= twine
-commands=
+deps = twine
+commands =
python setup.py sdist bdist_wheel
twine upload dist/*