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: Ie14819fe7be1fc6d7d8e04f2aa9f123bb6ad17e6
tags/1.1.0
huang.zhiping 1 year ago
parent
commit
86f514e9cc
1 changed files with 5 additions and 0 deletions
  1. 5
    0
      tox.ini

+ 5
- 0
tox.ini View File

@@ -20,14 +20,17 @@ deps = -r{toxinidir}/requirements.txt
20 20
 commands = {toxinidir}/manage.py test karbor_dashboard --settings=karbor_dashboard.test.settings
21 21
 
22 22
 [testenv:pep8]
23
+basepython = python3
23 24
 commands =
24 25
   /bin/bash run_tests.sh -N --pep8
25 26
   /bin/bash run_tests.sh -N --makemessages --check-only
26 27
 
27 28
 [testenv:venv]
29
+basepython = python3
28 30
 commands = {posargs}
29 31
 
30 32
 [testenv:cover]
33
+basepython = python3
31 34
 commands = /bin/bash run_tests.sh -N --no-pep8 --coverage {posargs}
32 35
 
33 36
 [testenv:py27dj18]
@@ -40,12 +43,14 @@ basepython = python2.7
40 43
 commands = /bin/bash run_tests.sh -N --integration --selenium-headless {posargs}
41 44
 
42 45
 [testenv:eslint]
46
+basepython = python3
43 47
 passenv = *
44 48
 commands = nodeenv -p
45 49
            npm install
46 50
            /bin/bash run_tests.sh -N --eslint
47 51
 
48 52
 [testenv:docs]
53
+basepython = python3
49 54
 setenv = DJANGO_SETTINGS_MODULE=openstack_dashboard.test.settings
50 55
 commands = python setup.py build_sphinx
51 56
 

Loading…
Cancel
Save