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: I380c7b2010248a257612ad707a69b433054d7a4a
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Doug Hellmann 6 months ago
parent
commit
1c2b7c734f
1 changed files with 4 additions and 1 deletions
  1. 4
    1
      tox.ini

+ 4
- 1
tox.ini View File

@@ -19,6 +19,7 @@ commands = stestr run {posargs}
19 19
            python {toxinidir}/tools/django-manage.py test bgpvpn_dashboard
20 20
 
21 21
 [testenv:releasenotes]
22
+basepython = python3
22 23
 deps = -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
23 24
        -r{toxinidir}/doc/requirements.txt
24 25
 commands = sphinx-build -W -a -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
@@ -82,10 +83,11 @@ setenv =
82 83
 setenv = OS_FAIL_ON_MISSING_DEPS=1
83 84
 
84 85
 [testenv:venv]
86
+basepython = python3
85 87
 commands = {posargs}
86 88
 
87 89
 [testenv:cover]
88
-basepython = python2.7
90
+basepython = python3
89 91
 setenv =
90 92
     PYTHON = coverage run --source networking_bgpvpn --parallel-mode
91 93
 commands =
@@ -95,6 +97,7 @@ commands =
95 97
     coverage xml -o cover/coverage.xml
96 98
 
97 99
 [testenv:docs]
100
+basepython = python3
98 101
 deps = -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
99 102
        -r{toxinidir}/doc/requirements.txt
100 103
 commands = python setup.py build_sphinx

Loading…
Cancel
Save