Pillow/tox.ini
Jon Dufresne e19d8dd84b Add linting to the tox matrix
Allows contributors to easily run the lint stage with a single command:
`tox -e lint`. This creates shorter round trips with CI in case of an
error.

Update the Travis configuration to use the new environment to run lint.
This allows using a single/common source of truth to reduce differences
between Travis and local testing.

The tox environment uses the skip_install feature as static analysis
doesn't requiring install the Pillow package itself to run. This feature
requires tox 1.9 (2015-02-24), so a minimum tox version was added to the
configuration.

https://tox.readthedocs.io/en/latest/config.html#conf-skip_install
2019-01-13 08:55:06 -08:00

33 lines
683 B
INI

# Tox (https://tox.readthedocs.io/en/latest/) is a tool for running tests
# in multiple virtualenvs. This configuration file will run the
# test suite on all supported python versions. To use it, "pip install tox"
# and then run "tox" from this directory.
[tox]
envlist =
lint
py{27,34,35,36,37}
minversion = 1.9
[testenv]
commands =
{envpython} setup.py clean
{envpython} setup.py build_ext --inplace
{envpython} selftest.py
{envpython} -m pytest -qq {posargs}
deps =
cffi
numpy
olefile
pyroma
pytest
[testenv:lint]
commands =
flake8 --statistics --count
check-manifest
deps =
check-manifest
flake8
skip_install = true