Magnum's tox test should respect upper-constraints

This will force pip install to use the upper-constraints.txt specified
version of pip modules. When you don't do this, you are out on the
bleeding edge and become unstable everytime some python library in the
wide world changes in a way that you don't expect.

Change-Id: I962329075b11d3790dc586ba33fe19fc64f1e4f9
Closes-Bug: #1563038
This commit is contained in:
Niall Bunting 2016-03-31 15:59:11 +00:00
parent a87603bd90
commit dbcfe35111
1 changed files with 8 additions and 1 deletions

View File

@ -7,7 +7,7 @@ skipsdist = True
usedevelop = True
install_command =
constraints: {[testenv:common-constraints]install_command}
pip install -U {opts} {packages}
pip install -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} -U {opts} {packages}
whitelist_externals = bash
find
setenv =
@ -99,6 +99,10 @@ deps = {[testenv:bandit]deps}
commands = {[testenv:bandit]commands}
[testenv:cover]
# NOTE(NiallBunting) Infra does not support constraints for the cover
# job. While the file is set no file is there. Can be removed once infra
# changes this.
install_command = pip install -U {opts} {packages}
commands = python setup.py testr --coverage --testr-args='{posargs}'
coverage report
@ -107,6 +111,9 @@ install_command = {[testenv:common-constraints]install_command}
commands = python setup.py testr --coverage --testr-args='{posargs}'
[testenv:docs]
# NOTE(NiallBunting) This is a post job. So upper constraints will not
# apply here.
install_command = pip install -U {opts} {packages}
commands =
doc8 -e .rst specs/ doc/source/ contrib/ CONTRIBUTING.rst HACKING.rst README.rst
python setup.py build_sphinx