aboutsummaryrefslogtreecommitdiffstats
path: root/moonclient
diff options
context:
space:
mode:
authorasteroide <thomas.duval@orange.com>2015-09-18 12:19:10 +0200
committerasteroide <thomas.duval@orange.com>2015-09-18 12:19:10 +0200
commit667bcc34cf1db96dbf28aa50a65f365e0dc829e7 (patch)
tree3412c87b6ec251b3c10f4b5bdf6c7f54324d1154 /moonclient
parenta03ac963aaebfbeb85e54f1cab98bae8f940d0ac (diff)
Change the way the data strings are replaced to allow similar variables on the same line.
Change-Id: I0ba5f0151ebc144015196b758c1bde587da63e7b
Diffstat (limited to 'moonclient')
-rw-r--r--moonclient/moonclient/tests.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/moonclient/moonclient/tests.py b/moonclient/moonclient/tests.py
index 63f1ed14..1e1020bf 100644
--- a/moonclient/moonclient/tests.py
+++ b/moonclient/moonclient/tests.py
@@ -33,7 +33,7 @@ class TestsLaunch(Lister):
def __replace_var_in_str(self, data_str):
for exp in re.findall("\$\w+", data_str):
if exp.replace("$", "") in self.result_vars:
- data_str = data_str.replace(exp, self.result_vars[exp.replace("$", "")])
+ data_str = re.sub(exp.replace("$", "\$") + "(?=$|\s)", self.result_vars[exp.replace("$", "")], data_str)
return data_str
def __compare_results(self, expected, observed):