summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHolger Krekel <holger@merlinux.eu>2016-06-20 18:17:41 +0200
committerHolger Krekel <holger@merlinux.eu>2016-06-20 18:17:41 +0200
commitd467ba8e26bb70d4abc7b951332701ffca7fc118 (patch)
treeba34d9ba6e80aaf9ddfa2e83a4827201c9a7fc0c
parent5a733959061ee97a6d24a32d61694a1f4ea9ab5f (diff)
parentfcc2506142ce6b0b3df29586c8f9ad6ac2a014b8 (diff)
downloadtox-d467ba8e26bb70d4abc7b951332701ffca7fc118.tar.gz
Merged in jayvdb/tox (pull request #186)
Add test for double substitution using {{ }}
-rw-r--r--tests/test_config.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/test_config.py b/tests/test_config.py
index 08b2f23..c31ca4f 100644
--- a/tests/test_config.py
+++ b/tests/test_config.py
@@ -1083,6 +1083,20 @@ class TestConfigTestEnv:
argv = conf.commands
assert argv[0] == ["echo"]
+ def test_substitution_double(self, newconfig):
+ inisource = """
+ [params]
+ foo = bah
+ foo2 = [params]foo
+
+ [testenv:py27]
+ commands =
+ echo {{[params]foo2}}
+ """
+ conf = newconfig([], inisource).envconfigs['py27']
+ argv = conf.commands
+ assert argv[0] == ['echo', 'bah']
+
def test_posargs_backslashed_or_quoted(self, tmpdir, newconfig):
inisource = """
[testenv:py27]