Install requirements during the correct tox phase

Glance isn't explicitly installing requirements, so add requirements
as tox deps in such a way that they'll be properly constrained by the
current openstack upper-constraints.

This change also bumps the version of psycopg to that of the current
upper-constraints in test-requirements and lower-constraints.  (The
version in our current lower-constraints is subject to the "could not
determine PostgreSQL version from '10.x'" error, which causes the
lower-constraints job to fail.)

Change-Id: I1bb5759e6b1e3f8545ab417617072a61323b59a7
Closes-bug: #1852356
This commit is contained in:
Brian Rosmaita 2019-11-12 19:30:46 -05:00
parent e45d5e3b92
commit d2d67ae3a1
3 changed files with 6 additions and 4 deletions

View File

@ -87,7 +87,7 @@ pika-pool==0.1.3
pika==0.10.0 pika==0.10.0
prettytable==0.7.1 prettytable==0.7.1
psutil==3.2.2 psutil==3.2.2
psycopg2==2.6.2 psycopg2==2.8.4
pycadf==2.7.0 pycadf==2.7.0
pycparser==2.18 pycparser==2.18
pyflakes==0.8.1 pyflakes==0.8.1

View File

@ -27,7 +27,7 @@ doc8>=0.6.0 # Apache-2.0
# Optional packages that should be installed when testing # Optional packages that should be installed when testing
PyMySQL>=0.7.6 # MIT License PyMySQL>=0.7.6 # MIT License
psycopg2>=2.6.2 # LGPL/ZPL psycopg2>=2.8.4 # LGPL/ZPL
pysendfile>=2.0.0;sys_platform!='win32' # MIT pysendfile>=2.0.0;sys_platform!='win32' # MIT
xattr>=0.9.2;sys_platform!='win32' # MIT xattr>=0.9.2;sys_platform!='win32' # MIT
python-swiftclient>=3.2.0 # Apache-2.0 python-swiftclient>=3.2.0 # Apache-2.0

View File

@ -18,8 +18,10 @@ setenv =
# clue for oslo.db to use file-based database. # clue for oslo.db to use file-based database.
OS_TEST_DBAPI_ADMIN_CONNECTION=sqlite:////tmp/placeholder-never-created-nor-used.db OS_TEST_DBAPI_ADMIN_CONNECTION=sqlite:////tmp/placeholder-never-created-nor-used.db
usedevelop = True usedevelop = True
install_command = pip install -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} {opts} {packages} install_command = pip install {opts} {packages}
deps = -r{toxinidir}/test-requirements.txt deps = -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/test-requirements.txt
-r{toxinidir}/requirements.txt
commands = commands =
find . -type f -name "*.pyc" -delete find . -type f -name "*.pyc" -delete
whitelist_externals = bash whitelist_externals = bash