diff options
author | holger krekel <holger@merlinux.eu> | 2015-06-19 11:13:38 +0200 |
---|---|---|
committer | holger krekel <holger@merlinux.eu> | 2015-06-19 11:13:38 +0200 |
commit | ef513813161200205ec89a2d824c0c80466c993f (patch) | |
tree | 0b78449509619c950ab9fe25bca62cf048f0ca3c | |
parent | 5acb7faa85936e208b17b7ef79618fcb790bafc6 (diff) | |
parent | 435c0f3ce28a436fda2464c4200370c35b22c609 (diff) | |
download | tox-ef513813161200205ec89a2d824c0c80466c993f.tar.gz |
Merged in acaron/tox (pull request #163)
Adds support for multiline envlist setting.
-rw-r--r-- | tests/test_config.py | 11 | ||||
-rw-r--r-- | tox/config.py | 2 |
2 files changed, 13 insertions, 0 deletions
diff --git a/tests/test_config.py b/tests/test_config.py index fae1bde..248f1d6 100644 --- a/tests/test_config.py +++ b/tests/test_config.py @@ -1323,6 +1323,17 @@ class TestGlobalOptions: assert config.envlist == \ ["py26-dep1", "py26-dep2", "py27-dep1", "py27-dep2"] + def test_envlist_multiline(self, newconfig): + inisource = """ + [tox] + envlist = + py27 + py34 + """ + config = newconfig([], inisource) + assert config.envlist == \ + ["py27", "py34"] + def test_minversion(self, tmpdir, newconfig, monkeypatch): inisource = """ [tox] diff --git a/tox/config.py b/tox/config.py index 062992e..177bfcc 100644 --- a/tox/config.py +++ b/tox/config.py @@ -733,6 +733,8 @@ class parseini: def _split_env(env): """if handed a list, action="append" was used for -e """ if not isinstance(env, list): + if '\n' in env: + env = ','.join(env.split('\n')) env = [env] return mapcat(_expand_envstr, env) |