Browse code

Handle common and seperate tempest tox venvs

In order to support the effort to unify the tox venvs being created
by tempest this commit temporarily cases the path of the venv being
created. Once tempest is updated to only use .tox/tempest we can
remove the if blocks and just use it unconditionally.

Change-Id: I34a69020eee07156e64026781a3c0bffdb5ab415
(cherry picked from commit 412956a9738fa5c56aad6837a090bd2d1a3c50bf)
(cherry picked from commit 0945f431c09620e6699ad6f18969ffcaaa51c773)

Matthew Treinish authored on 2016/05/03 05:33:29
Showing 1 changed files
... ...
@@ -620,7 +620,16 @@ function install_tempest {
620 620
     pip_install tox
621 621
     pushd $TEMPEST_DIR
622 622
     tox --notest -efull
623
-    PROJECT_VENV["tempest"]=${TEMPEST_DIR}/.tox/full
623
+    # NOTE(mtreinish) Respect constraints in the tempest full venv, things that
624
+    # are using a tox job other than full will not be respecting constraints but
625
+    # running pip install -U on tempest requirements
626
+    if [[ -d .tox/tempest ]] ; then
627
+        $TEMPEST_DIR/.tox/tempest/bin/pip install -c $REQUIREMENTS_DIR/upper-constraints.txt -r requirements.txt
628
+        PROJECT_VENV["tempest"]=${TEMPEST_DIR}/.tox/tempest
629
+    else
630
+        $TEMPEST_DIR/.tox/full/bin/pip install -c $REQUIREMENTS_DIR/upper-constraints.txt -r requirements.txt
631
+        PROJECT_VENV["tempest"]=${TEMPEST_DIR}/.tox/full
632
+    fi
624 633
     install_tempest_lib
625 634
     popd
626 635
 }