From 485fe226ec2839895aa1e648a28422ca8729b27d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Beraud?= Date: Wed, 15 Jan 2020 09:51:30 +0100 Subject: [PATCH] Stop configuring install_command in tox. Currently, we are overriding 'install_command' to use 'pip'. This is considered poor behavior and 'python -m pip' should be used instead: https://snarky.ca/why-you-should-use-python-m-pip/ It turns out that this is the the default value provided by tox: https://tox.readthedocs.io/en/latest/config.html#conf-install_command So we can remove the line and simply use the default value. Also these changes introduce a new explicit env var related to eventlet testing to avoid misunderstand. Change-Id: I03b9b179c4cb6ea5a9a8d8c74af3502a0243ace6 --- tox.ini | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tox.ini b/tox.ini index 3e1d776..9507987 100644 --- a/tox.ini +++ b/tox.ini @@ -5,7 +5,6 @@ ignore_basepython_conflict = True [testenv] basepython = python3 -install_command = pip install {opts} {packages} deps = -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} -r{toxinidir}/test-requirements.txt @@ -13,7 +12,7 @@ deps = # We want to support both vanilla stdlib and eventlet monkey patched whitelist_externals = env commands = - lockutils-wrapper stestr run --slowest {posargs} + env TEST_EVENTLET=0 lockutils-wrapper stestr run --slowest {posargs} env TEST_EVENTLET=1 lockutils-wrapper stestr run --slowest {posargs} [testenv:pep8]