Use stable constraints in Tempest tox till stable/rocky
Stable branches till stable/rocky is using python
version <py3.6. Tempest test those branch in venv
but Tempest tox use the master upper-constraint[1]
which block installation due to dependencies
require >=py3.6. For exmaple, oslo.concurrency 4.0.0
is not compatible for <py3.6.
As we pin Tempest for EM stable brach, we should be
able to use stable constraint for Tempest installation
as well as while running during run-tempest playbook.
tox.ini is hard coded to use master constraint[1] which force
legacy ocata job to use the master constraints and fail
- https://review.opendev.org/#/c/706161/
Devstack can set stable u-c to use via env var but this is
not enough as Tempest recreate the tox env with master u-c
when run test via devstack-gate.
All other branches have been fixed by fixing the run-tempest playbooks
in same way.
- https://review.opendev.org/#/c/705870/
Because stable/ocata and grenade job use devstack-gate, we need to fix this.
This is required to fix the grenade jobs on each stable branch to
get the other fixes in.
[1] bc9fe8eca8/tox.ini (L14)
Change-Id: Ibfc5c3d5e64e274fd674e6c42878d98bb194fa73
This commit is contained in:
parent
a9b0d5ddb1
commit
51a074c302
|
@ -859,12 +859,24 @@ if [[ "$DEVSTACK_GATE_TEMPEST" -eq "1" ]]; then
|
||||||
# something is wrong, to enforce exit on bad test results.
|
# something is wrong, to enforce exit on bad test results.
|
||||||
set -o errexit
|
set -o errexit
|
||||||
|
|
||||||
if [[ "${TEMPEST_OS_TEST_TIMEOUT:-}" != "" ]] ; then
|
# NOTE(gmann): Use branch constraint because Tempest is pinned to the branch release
|
||||||
TEMPEST_COMMAND="sudo -H -u tempest OS_TEST_TIMEOUT=$TEMPEST_OS_TEST_TIMEOUT tox"
|
# instead of using master. We need to export it via env var UPPER_CONSTRAINTS_FILE
|
||||||
|
# so that initial creation of tempest tox use stable branch constraint
|
||||||
|
# instead of master constraint as defined in tempest/tox.ini
|
||||||
|
stable_for_u_c="stable/[o-r]"
|
||||||
|
if [[ "$ZUUL_BRANCH" =~ $stable_for_u_c ]] ; then
|
||||||
|
export UPPER_CONSTRAINTS_FILE=$BASE/new/requirements/upper-constraints.txt
|
||||||
else
|
else
|
||||||
TEMPEST_COMMAND="sudo -H -u tempest tox"
|
export UPPER_CONSTRAINTS_FILE=https://releases.openstack.org/constraints/upper/master
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "${TEMPEST_OS_TEST_TIMEOUT:-}" != "" ]] ; then
|
||||||
|
TEMPEST_COMMAND="sudo -H -u tempest UPPER_CONSTRAINTS_FILE=$UPPER_CONSTRAINTS_FILE OS_TEST_TIMEOUT=$TEMPEST_OS_TEST_TIMEOUT tox"
|
||||||
|
else
|
||||||
|
TEMPEST_COMMAND="sudo -H -u tempest UPPER_CONSTRAINTS_FILE=$UPPER_CONSTRAINTS_FILE tox"
|
||||||
fi
|
fi
|
||||||
cd $BASE/new/tempest
|
cd $BASE/new/tempest
|
||||||
|
|
||||||
if [[ "$DEVSTACK_GATE_TEMPEST_REGEX" != "" ]] ; then
|
if [[ "$DEVSTACK_GATE_TEMPEST_REGEX" != "" ]] ; then
|
||||||
if [[ "$DEVSTACK_GATE_TEMPEST_ALL_PLUGINS" -eq "1" ]]; then
|
if [[ "$DEVSTACK_GATE_TEMPEST_ALL_PLUGINS" -eq "1" ]]; then
|
||||||
echo "Running tempest with plugins and a custom regex filter"
|
echo "Running tempest with plugins and a custom regex filter"
|
||||||
|
|
Loading…
Reference in New Issue