diff options
author | Linda Wang <wangwulin@huawei.com> | 2018-02-13 03:17:49 +0000 |
---|---|---|
committer | Linda Wang <wangwulin@huawei.com> | 2018-02-13 03:49:22 +0000 |
commit | ef798eee7e223b908361c7c79278cd347128a039 (patch) | |
tree | 633452756fd69c55ec7ce685a8e63f83e73305f4 /functest/api/resources/v1/tasks.py | |
parent | 7598ab763d31ca4f901043722c19635b73f00d3f (diff) |
Read env vars instead of using CONST in API
Also, improve the way of getting env values.
JIRA: FUNCTEST-933
Change-Id: Ia66bbaf683df03c2874fafe578b84bb78a4f3fd1
Signed-off-by: Linda Wang <wangwulin@huawei.com>
Diffstat (limited to 'functest/api/resources/v1/tasks.py')
-rw-r--r-- | functest/api/resources/v1/tasks.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/functest/api/resources/v1/tasks.py b/functest/api/resources/v1/tasks.py index 6bf625a8..5af8a678 100644 --- a/functest/api/resources/v1/tasks.py +++ b/functest/api/resources/v1/tasks.py @@ -85,7 +85,7 @@ class V1TaskLog(ApiResource): except ValueError: return api_utils.result_handler(status=1, data='No such task id') - task_log_dir = CONST.__getattribute__('dir_results') + task_log_dir = getattr(CONST, 'dir_results') # pylint: disable=maybe-no-member index = int(self._get_args().get('index', 0)) |