diff options
author | 2018-02-13 10:14:00 +0000 | |
---|---|---|
committer | 2018-02-13 10:14:00 +0000 | |
commit | ae6798b7018e609d7a4833599e7915cebc258ac5 (patch) | |
tree | 282ef0863bd3d3316ccfd6e20df185e527a5aa01 /functest/cli/commands/cli_os.py | |
parent | 5387e9adab29aa72a0cbdea0615799eccaf6781d (diff) | |
parent | dd168d1587838be11d7a8372f77b16915a3af85b (diff) |
Merge "Improve the way of getting env values"
Diffstat (limited to 'functest/cli/commands/cli_os.py')
-rw-r--r-- | functest/cli/commands/cli_os.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/functest/cli/commands/cli_os.py b/functest/cli/commands/cli_os.py index 7595caab..0cf28623 100644 --- a/functest/cli/commands/cli_os.py +++ b/functest/cli/commands/cli_os.py @@ -20,10 +20,10 @@ from functest.utils.constants import CONST class OpenStack(object): def __init__(self): - self.os_auth_url = CONST.__getattribute__('OS_AUTH_URL') + self.os_auth_url = os.environ['OS_AUTH_URL'] self.endpoint_ip = None self.endpoint_port = None - self.openstack_creds = CONST.__getattribute__('env_file') + self.openstack_creds = getattr(CONST, 'env_file') if self.os_auth_url: self.endpoint_ip = urllib.parse.urlparse(self.os_auth_url).hostname self.endpoint_port = urllib.parse.urlparse(self.os_auth_url).port |