Code Review
/
functest.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
4f488f1
)
Bugfix: remove double quotes from environment variables
63/28563/1
author
jose.lausuch
<jose.lausuch@ericsson.com>
Mon, 13 Feb 2017 23:10:06 +0000
(
00:10
+0100)
committer
jose.lausuch
<jose.lausuch@ericsson.com>
Mon, 13 Feb 2017 23:10:06 +0000
(
00:10
+0100)
JIRA: FUNCTEST-724
Change-Id: Iae248d710813a241752e1a06fb87d650caf3d188
Signed-off-by: jose.lausuch <jose.lausuch@ericsson.com>
functest/utils/openstack_utils.py
patch
|
blob
|
history
diff --git
a/functest/utils/openstack_utils.py
b/functest/utils/openstack_utils.py
index
a0d78ae
..
c21ed81
100755
(executable)
--- a/
functest/utils/openstack_utils.py
+++ b/
functest/utils/openstack_utils.py
@@
-114,7
+114,8
@@
def get_credentials(other_creds={}):
def source_credentials(rc_file):
with open(rc_file, "r") as f:
for line in f:
- var = line.rstrip('"\n').replace('export ', '').split("=")
+ var = line.rstrip('"\n').replace(
+ 'export ', '').replace("'", "").split("=")
key = re.sub(r'^ *| *$', '', var[0])
value = re.sub(r'^[" ]*|[ "]*$', '', "".join(var[1:]))
os.environ[key] = value