aboutsummaryrefslogtreecommitdiffstats
path: root/functest/utils/functest_utils.py
diff options
context:
space:
mode:
authorLinda Wang <wangwulin@huawei.com>2017-11-30 02:31:17 +0000
committerLinda Wang <wangwulin@huawei.com>2017-11-30 07:33:31 +0000
commit8b21d5190469230644506ec561762d452a46b933 (patch)
treea91f9083878a657915df8d84f93aba0eb5c1f7da /functest/utils/functest_utils.py
parente63b856182cb65f1943f83b672e7d9e8b9f3dc3e (diff)
Stop updating test_db_url in config file by env var
If TEST_DB_URL is declared in env variable, use it before considering the var in config file. Change-Id: I656ad8765287c48d60af7ab88b421805d76fb231 Signed-off-by: Linda Wang <wangwulin@huawei.com>
Diffstat (limited to 'functest/utils/functest_utils.py')
-rw-r--r--functest/utils/functest_utils.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/functest/utils/functest_utils.py b/functest/utils/functest_utils.py
index f07f59d7f..bbb6b631a 100644
--- a/functest/utils/functest_utils.py
+++ b/functest/utils/functest_utils.py
@@ -130,7 +130,10 @@ def push_results_to_db(project, case_name,
POST results to the Result target DB
"""
# Retrieve params from CI and conf
- url = CONST.__getattribute__("results_test_db_url")
+ if (hasattr(CONST, 'TEST_DB_URL')):
+ url = CONST.__getattribute__('TEST_DB_URL')
+ else:
+ url = CONST.__getattribute__("results_test_db_url")
try:
installer = os.environ['INSTALLER_TYPE']