From e5e795ac9f5077e15beac1cb36a14982ca04fd01 Mon Sep 17 00:00:00 2001 From: Cosimo Lupo Date: Mon, 10 Apr 2017 12:23:12 +0100 Subject: [PATCH] [tox] don't pass {posargs} to coverage in 'htmlcov' env The {posargs} are global for the current tox process, and we already use them to pass additional arguments to the pytest command in the default testenv, so we can't at the same time also use them to pass options to coverage.py. The 'htmlcov' tox environment produces the combined coverage.py report, and store it in htmlcov/index.html; this is listed in the tox.ini 'envlist', so it is run by default at every 'tox' invocation, when no explicit env list is passed via either -e option or $TOXENV variable. The options to `coverage html` are not much interesting anyway; it's much more useful being able to, e.g., run tox for specific tests matching a string or expression: $ tox -- -k "feaLib" --- tox.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index 50b6178ce..4966d8bf4 100644 --- a/tox.ini +++ b/tox.ini @@ -29,7 +29,7 @@ deps = skip_install = true commands = coverage combine - coverage html {posargs} + coverage html [testenv:codecov] passenv = *