Browse Source

fix tox python3 overrides

We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

We do not want to specify a minor version number, because we do not
want to have to update the file every time we upgrade python.

We do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: I6b35f4121e9742544cd8d365f46abda62454baba
tags/7.0.0
huang.zhiping 1 year ago
parent
commit
c8932b4f81
1 changed files with 6 additions and 0 deletions
  1. 6
    0
      tox.ini

+ 6
- 0
tox.ini View File

@@ -17,12 +17,15 @@ commands = stestr run {posargs}
17 17
 passenv = http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY
18 18
 
19 19
 [testenv:pep8]
20
+basepython = python3
20 21
 commands = flake8
21 22
 
22 23
 [testenv:venv]
24
+basepython = python3
23 25
 commands = {posargs}
24 26
 
25 27
 [testenv:cover]
28
+basepython = python3
26 29
 setenv =
27 30
   {[testenv]setenv}
28 31
   PYTHON=coverage run --source networking_fujitsu --parallel-mode
@@ -34,12 +37,15 @@ commands =
34 37
   coverage xml -o cover/coverage.xml
35 38
 
36 39
 [testenv:docs]
40
+basepython = python3
37 41
 commands = python setup.py build_sphinx
38 42
 
39 43
 [testenv:releasenotes]
44
+basepython = python3
40 45
 commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
41 46
 
42 47
 [testenv:debug]
48
+basepython = python3
43 49
 commands = oslo_debug_helper -t networking_fujitsu/tests {posargs}
44 50
 
45 51
 [flake8]

Loading…
Cancel
Save