[tox] envlist = test,flake8,black skipsdist = True [testenv] commands = test: {[testenv:test]commands} flake8: {[testenv:flake8]commands} black: {[testenv:black]commands} [testenv:test] deps = pytest -rrequirements.txt commands = pytest -v --doctest-modules [testenv:flake8] deps = flake8 commands = flake8 . [testenv:black] allowlist_externals = /usr/bin/bash /bin/bash deps = black commands = bash -c "black --check --diff --color tests/ *.py"