aboutsummaryrefslogtreecommitdiffstats
path: root/testcases/config_functest.py
diff options
context:
space:
mode:
Diffstat (limited to 'testcases/config_functest.py')
-rwxr-xr-xtestcases/config_functest.py46
1 files changed, 2 insertions, 44 deletions
diff --git a/testcases/config_functest.py b/testcases/config_functest.py
index d0788d30f..20d3a9dd7 100755
--- a/testcases/config_functest.py
+++ b/testcases/config_functest.py
@@ -59,8 +59,8 @@ ODL_DIR = REPO_PATH + functest_yaml.get("general").get("directories").get("dir_o
DATA_DIR = functest_yaml.get("general").get("directories").get("dir_functest_data")
# Tempest/Rally configuration details
-DEPLOYMENT_MAME = "opnfv-rally"
-RALLY_COMMIT = functest_yaml.get("general").get("openstack").get("rally_stable_commit")
+DEPLOYMENT_MAME = functest_yaml.get("rally").get("deployment_name")
+RALLY_COMMIT = functest_yaml.get("general").get("repositories").get("rally_commit")
#Image (cirros)
IMAGE_FILE_NAME = functest_yaml.get("general").get("openstack").get("image_file_name")
@@ -108,19 +108,12 @@ def action_start():
logger.info("Private network '%s' already existing in the deployment."
% private_net['name'])
-
logger.info("Installing Rally...")
if not install_rally():
logger.error("There has been a problem while installing Rally.")
action_clean()
exit(-1)
- logger.info("Configuring Tempest...")
- if not configure_tempest():
- logger.error("There has been a problem while configuring Tempest.")
- action_clean()
- exit(-1)
-
# Create result folder under functest if necessary
if not os.path.exists(RALLY_RESULT_DIR):
os.makedirs(RALLY_RESULT_DIR)
@@ -231,41 +224,6 @@ def install_rally():
return True
-def configure_tempest():
- """
- Add/update needed parameters into tempest.conf file generated by Rally
- """
-
- creds_neutron = functest_utils.get_credentials("neutron")
- neutron_client = neutronclient.Client(**creds_neutron)
-
- logger.debug("Generating tempest.conf file...")
- cmd = "rally verify genconfig"
- functest_utils.execute_command(cmd,logger)
-
- logger.debug("Resolving deployment UUID...")
- cmd = "rally deployment list | awk '/"+DEPLOYMENT_MAME+"/ {print $2}'"
- p = subprocess.Popen(cmd, shell=True,
- stdout=subprocess.PIPE,
- stderr=subprocess.STDOUT);
- deployment_uuid = p.stdout.readline().rstrip()
- if deployment_uuid == "":
- logger.debug(" Rally deployment NOT found")
- return False
-
- logger.debug("Finding tempest.conf file...")
- tempest_conf_file = RALLY_INSTALLATION_DIR+"/tempest/for-deployment-" \
- +deployment_uuid+"/tempest.conf"
-
- logger.debug(" Updating fixed_network_name...")
- fixed_network = functest_utils.get_network_list(neutron_client)[0]['name']
- if fixed_network != None:
- cmd = "crudini --set "+tempest_conf_file+" compute fixed_network_name "+fixed_network
- functest_utils.execute_command(cmd,logger)
-
- return True
-
-
def check_rally():
"""
Check if Rally is installed and properly configured