From 741a052bd607ac3cc838ea59632c5313c34e2d08 Mon Sep 17 00:00:00 2001 From: boucherv Date: Mon, 4 Jan 2016 11:36:18 +0100 Subject: Ensure that ruby libraries was installed before running vims test-case Change-Id: Ice896c37fc28e01f260cd617ee4c38d323607bb5 Signed-off-by: boucherv --- testcases/config_functest.py | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'testcases/config_functest.py') diff --git a/testcases/config_functest.py b/testcases/config_functest.py index 20d3a9dd..5af2975b 100755 --- a/testcases/config_functest.py +++ b/testcases/config_functest.py @@ -55,6 +55,7 @@ RALLY_REPO_DIR = functest_yaml.get("general").get("directories").get("dir_repo_r RALLY_INSTALLATION_DIR = functest_yaml.get("general").get("directories").get("dir_rally_inst") RALLY_RESULT_DIR = functest_yaml.get("general").get("directories").get("dir_rally_res") VPING_DIR = REPO_PATH + functest_yaml.get("general").get("directories").get("dir_vping") +VIMS_TEST_DIR = functest_yaml.get("general").get("directories").get("dir_repo_vims_test") ODL_DIR = REPO_PATH + functest_yaml.get("general").get("directories").get("dir_odl") DATA_DIR = functest_yaml.get("general").get("directories").get("dir_functest_data") @@ -114,6 +115,14 @@ def action_start(): action_clean() exit(-1) + # Install ruby libraries for vims test-case + script += 'source /etc/profile.d/rvm.sh; ' + script += 'cd ' + VIMS_TEST_DIR + '; ' + script += 'bundle install' + + cmd = "/bin/bash -c '" + script + "'" + functest_utils.execute_command(cmd,logger) + # Create result folder under functest if necessary if not os.path.exists(RALLY_RESULT_DIR): os.makedirs(RALLY_RESULT_DIR) -- cgit 1.2.3-korg