aboutsummaryrefslogtreecommitdiffstats
path: root/functest/utils/functest_utils.py
diff options
context:
space:
mode:
authorMorgan Richomme <morgan.richomme@orange.com>2017-02-06 10:58:40 +0100
committerMorgan Richomme <morgan.richomme@orange.com>2017-02-06 10:58:40 +0100
commitb8648aa157d36e93fcd7849e41985ff88222de44 (patch)
treecf62738c5c7fbb14895129ddb373e2bd730fa240 /functest/utils/functest_utils.py
parent9ed4cad5955d0b8815a5e0c3b10be715de82197a (diff)
Change log level when pod, scenario or build_tag cannot be retrieved
when using Functest out of CI, such env variables may not be set This shall not result in Error messages JIRA: FUNCTEST-716 Change-Id: I86d2023145480dfa9c8d593ea274acbd9e431ef7 Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
Diffstat (limited to 'functest/utils/functest_utils.py')
-rw-r--r--functest/utils/functest_utils.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/functest/utils/functest_utils.py b/functest/utils/functest_utils.py
index 2bf87a05..04055464 100644
--- a/functest/utils/functest_utils.py
+++ b/functest/utils/functest_utils.py
@@ -96,8 +96,9 @@ def get_scenario():
try:
scenario = os.environ['DEPLOY_SCENARIO']
except KeyError:
- logger.error("Impossible to retrieve the scenario")
- scenario = "Unknown_scenario"
+ logger.info("Impossible to retrieve the scenario."
+ "Use default os-nosdn-nofeature-noha")
+ scenario = "os-nosdn-nofeature-noha"
return scenario
@@ -128,7 +129,7 @@ def get_pod_name():
try:
return os.environ['NODE_NAME']
except KeyError:
- logger.error(
+ logger.info(
"Unable to retrieve the POD name from environment. " +
"Using pod name 'unknown-pod'")
return "unknown-pod"
@@ -141,8 +142,8 @@ def get_build_tag():
try:
build_tag = os.environ['BUILD_TAG']
except KeyError:
- logger.error("Impossible to retrieve the build tag")
- build_tag = "unknown_build_tag"
+ logger.info("Impossible to retrieve the build tag")
+ build_tag = "none"
return build_tag