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 can't set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36 due to https://github.com/tox-dev/tox/issues/425

Change-Id: Ibeb97401c13fb1cb35f824082eb6b3209c868beb
huang.zhiping 10 months ago
parent
commit
d5cbd03a57
1 changed files with 6 additions and 0 deletions
  1. 6
    0
      tox.ini

+ 6
- 0
tox.ini View File

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

Loading…
Cancel
Save