Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
tox commands now have {posargs} as argument
When invoking an environement, one might want to pass extra argument to
the command. That is done in tox by invoking an env and passing the
extra arguments after '--' which are then available as '{posargs}'.

Examples:

  # Reports flake8 error statistics
  tox -eflake8 -- --statistics

  # Only run test_util.py tests, printing a line per test:
  tox -epy27 -- --verbose  git/test/test_util.py
  • Loading branch information
hashar committed Nov 14, 2014
commit 18fff4d4a28295500acd531a1b97bc3b89fad07e
6 changes: 3 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
envlist = py26,py27,flake8

[testenv]
commands = nosetests
commands = nosetests {posargs}
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt

[testenv:cover]
commands = nosetests --with-coverage
commands = nosetests --with-coverage {posargs}

[testenv:flake8]
commands = flake8
commands = flake8 {posargs}

[testenv:venv]
commands = {posargs}
Expand Down