Merge branch 'varfind-cleanups' of git://github.com/dhozac/ansible into devel

This commit is contained in:
Michael DeHaan
2012-10-25 20:14:20 -04:00
2 changed files with 47 additions and 37 deletions

View File

@@ -230,6 +230,14 @@ class TestUtils(unittest.TestCase):
res = ansible.utils.varReplace(template, vars, expand_lists=True)
assert res == 'yum pkg=foo,bar,baz state=installed'
def test_varReplace_escaped_var(self):
vars = {
'foo': 'bar',
}
template = 'action \$foo'
res = ansible.utils.varReplace(template, vars)
assert res == 'action $foo'
def test_template_varReplace_iterated(self):
template = 'hello $who'
vars = {