Skip to content

Commit

Permalink
Split code and docs style commands for tox
Browse files Browse the repository at this point in the history
(Python only)

tox -e flake8
checks code style

and
tox -e pydocstyle
checks code documentation style.
  • Loading branch information
chovanecm committed Jun 6, 2017
1 parent a9674e5 commit 53ffcb4
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ env:
- TOX_ENV=py34
- TOX_ENV=py35
- TOX_ENV=flake8
- TOX_ENV=pydocstyle
- TOX_ENV=coverage
script:
- tox -e $TOX_ENV
Expand Down
10 changes: 8 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,26 @@
# and then run "tox" from this directory.

[tox]
envlist = py34, py35, flake8, qunit, eslint
envlist = py34, py35, flake8, pydocstyle, qunit, eslint

[testenv]
commands = {envpython} setup.py test --addopts -v

[testenv:flake8]
deps =
flake8
pydocstyle
commands =
flake8 sacredboard --max-complexity 10 --exclude tests

[testenv:pydocstyle]
deps =
pydocstyle
commands =
pydocstyle sacredboard --ignore D207,D212,D301,D203

# pydocstyle ignores some warnings because of the sacredboard command line help docstring
# and because some are mutually exclusive

[testenv:coverage]
passenv = TRAVIS TRAVIS_JOB_ID TRAVIS_BRANCH
deps =
Expand Down

0 comments on commit 53ffcb4

Please sign in to comment.