From c9a5db71e889e0c16bffb3148936311bfb91c6ff Mon Sep 17 00:00:00 2001
From: vponomaryov <vponomaryov@mirantis.com>
Date: Thu, 27 Feb 2014 22:36:57 +0200
Subject: [PATCH] Fixed update of env var in manila's job

It was running only first part of tests, defined in 'export' string, and never
second part, that is in condition of pre_test_hook.
Moved update of env var 'MANILA_TESTS' from pre_test_hook to top, because it
hasn't changed exported value.
Also fixed condition itself, that always was 'true'.

Change-Id: I292c45caaf66be0c7d0018ebc84686324298c2f1
---
 .../files/jenkins_job_builder/config/manila.yaml            | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/modules/openstack_project/files/jenkins_job_builder/config/manila.yaml b/modules/openstack_project/files/jenkins_job_builder/config/manila.yaml
index 574515c016..f0b2a892d5 100644
--- a/modules/openstack_project/files/jenkins_job_builder/config/manila.yaml
+++ b/modules/openstack_project/files/jenkins_job_builder/config/manila.yaml
@@ -22,6 +22,9 @@
           export TEMPEST_CONCURRENCY=1
           export KEEP_LOCALRC=1
           export MANILA_TESTS='tempest.cli.*manila*'
+          if [[ ! "$ZUUL_PROJECT" =~ python-manilaclient ]]; then
+              MANILA_TESTS+=' tempest.api.share*';
+          fi
           echo "API_RATE_LIMIT=False" >> localrc
           echo "SHARE_BACKING_FILE_SIZE=12G" >> localrc
           echo "VOLUME_BACKING_FILE_SIZE=12G" >> localrc
@@ -31,9 +34,6 @@
               cp -r $BASE/new/manila/contrib/devstack/* $BASE/new/devstack
               # Install manila tempest integration
               cp -r $BASE/new/manila/contrib/tempest/tempest/* $BASE/new/tempest/tempest
-              if [[ ! "$ZUUL_PROJECT" =~ "*python-manilaclient*" ]]; then
-                MANILA_TESTS+=' tempest.api.share*';
-              fi
           }
           export -f pre_test_hook