remove unused gate code

* post_test_hook. used in legacy gate
* run_functional_test probably not used and also doean't work
  since mistral_tempest was moved

Change-Id: Ib54940fdf3db7afff945f7c13d158cc04f5ac250
This commit is contained in:
Eyal 2019-09-01 11:21:21 +03:00
parent 2cdcb5415e
commit 8d53992116
3 changed files with 0 additions and 121 deletions

View File

@ -1,33 +0,0 @@
#!/bin/bash
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
# This script is executed inside post_test_hook function in devstack gate.
set -ex
sudo chmod -R a+rw /opt/stack/
(cd $BASE/new/tempest/; sudo virtualenv .venv)
source $BASE/new/tempest/.venv/bin/activate
(cd $BASE/new/tempest/; sudo pip install -r requirements.txt -r test-requirements.txt)
sudo pip install nose
sudo pip install numpy
sudo cp $BASE/new/tempest/etc/logging.conf.sample $BASE/new/tempest/etc/logging.conf
(cd $BASE/new/mistral/; sudo pip install -r requirements.txt -r test-requirements.txt)
(cd $BASE/new/mistral/; sudo python setup.py install)
export TOX_TESTENV_PASSENV=ZUUL_PROJECT
(cd $BASE/new/tempest/; sudo -E tox -evenv-tempest -- tempest run -r mistral)

View File

@ -1,41 +0,0 @@
#!/bin/bash
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
# How many seconds to wait for the API to be responding before giving up
API_RESPONDING_TIMEOUT=20
if ! timeout ${API_RESPONDING_TIMEOUT} sh -c "until curl --output /dev/null --silent --head --fail http://localhost:8989; do sleep 1; done"; then
echo "Mistral API failed to respond within ${API_RESPONDING_TIMEOUT} seconds"
exit 1
fi
echo "Successfully contacted Mistral API"
# Where tempest code lives
TEMPEST_DIR=${TEMPEST_DIR:-/opt/stack/tempest}
# Path to directory with tempest.conf file, otherwise it will
# take relative path from where the run tests command is being executed.
export TEMPEST_CONFIG_DIR=${TEMPEST_CONFIG_DIR:-$TEMPEST_DIR/etc/}
echo "Tempest configuration file directory: $TEMPEST_CONFIG_DIR"
# Where mistral code and mistralclient code live
MISTRAL_DIR=/opt/stack/mistral
MISTRALCLIENT_DIR=/opt/stack/python-mistralclient
# Define PYTHONPATH
export PYTHONPATH=$PYTHONPATH:$TEMPEST_DIR
pwd
nosetests -sv mistral_tempest_tests/tests/

View File

@ -1,47 +0,0 @@
#! /usr/bin/env bash
ARG=$1
function pre_hook() {
export WITHOUT_AUTH="True"
IS_TEMPEST=$(pip freeze | grep tempest)
if [ -z "$IS_TEMPEST" ]
then echo "$(tput setaf 4)No such module 'tempest' in the system. Before running this script please install 'tempest' module using : pip install git+http://github.com/openstack/tempest.git$(tput sgr 0)"
exit 1
fi
}
function run_tests_by_version() {
echo "$(tput setaf 4)Running integration API and workflow execution tests for v$1$(tput sgr 0)"
export VERSION="v$1"
nosetests -v mistral_tempest_tests/tests/api/v$1/
unset VERSION
}
function run_tests() {
if [ -z "$ARG" ]
then
run_tests_by_version 1
run_tests_by_version 2
elif [ "$ARG" == "v1" ]
then
run_tests_by_version 1
elif [ "$ARG" == "v2" ]
then
run_tests_by_version 2
fi
}
function post_hook () {
unset LOCAL_RUN
}
#----------main-part----------
echo "$(tput setaf 4)Preparation for tests running...$(tput sgr 0)"
pre_hook
echo "$(tput setaf 4)Running tests...$(tput sgr 0)"
run_tests
post_hook