From: Matthew Oliver Date: Thu, 2 Apr 2020 23:22:02 +0000 (+0000) Subject: tox: Fix the tox.ini's to support older versions of tox X-Git-Tag: v16.1.0~2671^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F34383%2Fhead;p=ceph.git tox: Fix the tox.ini's to support older versions of tox The src/cephadm/tox.ini and src/pybind/mgr/tox.ini both don't run on older versions of tox. When using tox 2.9.1 both fail for different reasons. `src/cephadm/tox.ini` fails because `skipsdist=true` only works if it's directly under the `[tox]` section. `src/pybind/mgr/tox.ini` fails because older versions of tox can't find the requirements.txt because they don't like whitespace between the `-r` and `requirements.txt`. This patch changes the tox.ini's to be backwards compatible for those who happen to be running slightly older version of tox. Signed-off-by: Matthew Oliver --- diff --git a/src/cephadm/tox.ini b/src/cephadm/tox.ini index 66edfe99f2a..59d94a4c4c0 100644 --- a/src/cephadm/tox.ini +++ b/src/cephadm/tox.ini @@ -1,8 +1,8 @@ [tox] envlist = py27, py3, mypy +skipsdist=true [testenv] -skipsdist=true skip_install=true deps = pytest diff --git a/src/pybind/mgr/tox.ini b/src/pybind/mgr/tox.ini index 10694f05995..d04c889db0a 100644 --- a/src/pybind/mgr/tox.ini +++ b/src/pybind/mgr/tox.ini @@ -10,14 +10,14 @@ setenv = LD_LIBRARY_PATH = ../../../build/lib deps = cython - -r requirements.txt + -rrequirements.txt commands = pytest -v --cov --cov-append --cov-report= --doctest-modules {posargs:mgr_util.py tests/ cephadm/ pg_autoscaler/ progress/} [testenv:mypy] basepython = python3 deps = cython - -r requirements.txt + -rrequirements.txt mypy==0.770 commands = mypy --config-file=../../mypy.ini \ cephadm/module.py \