From 93763eb41c318e021f9c69093ce013dcb021f59b Mon Sep 17 00:00:00 2001 From: Matthew Oliver Date: Thu, 2 Apr 2020 23:22:02 +0000 Subject: [PATCH] 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 (cherry picked from commit a1fd9d11e7e11a2478f268251a4a02f2d260fc1c) --- src/cephadm/tox.ini | 2 +- src/pybind/mgr/tox.ini | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/cephadm/tox.ini b/src/cephadm/tox.ini index 66edfe99f2ac2..59d94a4c4c0f8 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 10694f05995e1..d04c889db0a5e 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 \ -- 2.39.5