summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG1
-rw-r--r--CONTRIBUTORS1
-rw-r--r--tests/test_config.py15
-rw-r--r--tox/session.py2
4 files changed, 18 insertions, 1 deletions
diff --git a/CHANGELOG b/CHANGELOG
index 04f64159..8bdb5b8d 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -2,6 +2,7 @@ Not released yet
----
- #474: Start using setuptools_scm for tag based versioning.
+- #506: With `-a`: do not show additional environments header if there are none
2.7.0
-----
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 66ca1c72..1a163474 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -23,6 +23,7 @@ Carl Meyer
Anthon van der Neuth
Matt Good
Mattieu Agopian
+Mikhail Kyshtymov
Asmund Grammeltwedt
Ionel Maries Cristian
Julian Krause
diff --git a/tests/test_config.py b/tests/test_config.py
index d03a5d29..4eac45e6 100644
--- a/tests/test_config.py
+++ b/tests/test_config.py
@@ -2085,6 +2085,21 @@ class TestCmdInvocation:
docs -> generate documentation
""")
+ def test_listenvs_all_verbose_description_no_additional_environments(self, cmd, initproj):
+ initproj('listenvs_all_verbose_description', filedefs={
+ 'tox.ini': '''
+ [tox]
+ envlist=py27,py36
+ ''',
+ })
+ result = cmd.run("tox", "-av")
+ result.stdout.fnmatch_lines("""
+ default environments:
+ py27 -> [no description]
+ py36 -> [no description]
+ """)
+ assert 'additional environments' not in result.stdout.str()
+
def test_config_specific_ini(self, tmpdir, cmd):
ini = tmpdir.ensure("hello.ini")
result = cmd.run("tox", "-c", ini, "--showconfig")
diff --git a/tox/session.py b/tox/session.py
index cd17ead8..fd726ac5 100644
--- a/tox/session.py
+++ b/tox/session.py
@@ -645,7 +645,7 @@ class Session:
self.report.line(msg)
for e in default:
report_env(e)
- if all_envs:
+ if all_envs and extra:
if description:
self.report.line('')
self.report.line('additional environments:')