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: I6afd558c47021ecbee120828bfa6ba05eb4880a9
huang.zhiping 10 months ago
parent
commit
dd8068add3
1 changed files with 6 additions and 0 deletions
  1. 6
    0
      tox.ini

+ 6
- 0
tox.ini View File

@@ -13,22 +13,28 @@ deps = -r{toxinidir}/test-requirements.txt
13 13
 commands = python setup.py test --slowest --testr-args='{posargs}'
14 14
 
15 15
 [testenv:pep8]
16
+basepython = python3
16 17
 commands = flake8 {posargs}
17 18
 
18 19
 [testenv:venv]
20
+basepython = python3
19 21
 commands = {posargs}
20 22
 
21 23
 [testenv:cover]
24
+basepython = python3
22 25
 commands = python setup.py test --coverage --testr-args='{posargs}'
23 26
 
24 27
 [testenv:docs]
28
+basepython = python3
25 29
 commands = python setup.py build_sphinx
26 30
 
27 31
 [testenv:releasenotes]
32
+basepython = python3
28 33
 commands =
29 34
   sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
30 35
 
31 36
 [testenv:debug]
37
+basepython = python3
32 38
 commands = oslo_debug_helper {posargs}
33 39
 
34 40
 [flake8]

Loading…
Cancel
Save