diff options
| author | Zuul <zuul@review.openstack.org> | 2018-07-19 17:26:45 +0000 |
|---|---|---|
| committer | Gerrit Code Review <review@openstack.org> | 2018-07-19 17:26:45 +0000 |
| commit | f69bfcbd7ffbdcd45e36768b760e53bd1c1c32d3 (patch) | |
| tree | 3f7a972ac1e011cbb3960996994799bcf1947c19 | |
| parent | 90727008876ef35d3135d494aeb45bdf2f63e8fc (diff) | |
| parent | 9b0c6c46f6ff63febcbea9476e043c64b603ee02 (diff) | |
| download | python-cinderclient-f69bfcbd7ffbdcd45e36768b760e53bd1c1c32d3.tar.gz | |
Merge "fix tox python3 overrides"
| -rw-r--r-- | cinderclient/utils.py | 2 | ||||
| -rw-r--r-- | tox.ini | 7 |
2 files changed, 8 insertions, 1 deletions
diff --git a/cinderclient/utils.py b/cinderclient/utils.py index 0d8408e..f9af58d 100644 --- a/cinderclient/utils.py +++ b/cinderclient/utils.py @@ -187,7 +187,7 @@ def print_list(objs, fields, exclude_unavailable=False, formatters=None, def _encode(src): """remove extra 'u' in PY2.""" - if six.PY2 and isinstance(src, unicode): + if six.PY2 and isinstance(src, six.text_type): return src.encode('utf-8') return src @@ -24,9 +24,11 @@ commands = find . -type f -name "*.pyc" -delete whitelist_externals = find [testenv:pep8] +basepython = python3 commands = flake8 [testenv:pylint] +basepython = python3 deps = -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} -r{toxinidir}/requirements.txt @@ -35,9 +37,11 @@ commands = bash tools/lintstack.sh whitelist_externals = bash [testenv:venv] +basepython = python3 commands = {posargs} [testenv:cover] +basepython = python3 setenv = {[testenv]setenv} PYTHON=coverage run --source cinderclient --parallel-mode @@ -48,6 +52,7 @@ commands = coverage xml -o cover/coverage.xml [testenv:docs] +basepython = python3 deps = -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} -r{toxinidir}/requirements.txt @@ -55,6 +60,7 @@ deps = commands = sphinx-build -b html doc/source doc/build/html [testenv:releasenotes] +basepython = python3 deps = -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} -r{toxinidir}/requirements.txt @@ -62,6 +68,7 @@ deps = commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html [testenv:functional] +basepython = python3 commands = ostestr {posargs} setenv = {[testenv]setenv} |
