[tox]
minversion = 2.0
envlist = py{35,36,37,38,39},pypy3

[pytest]
addopts = -rs -v --showlocals
testpaths = tests

[testenv]
passenv = COLORTERM COLORFGBG SHELL TERM TERM_PROGRAM TERM_PROGRAM_VERSION ConEmuANSI
deps = pytest
commands = pytest

[testenv:scripts]
commands =
    python examples/autoreset_demo.py
    python examples/colorspaces.py
    python examples/highlight_differences.py
    python examples/humpty.py
    python examples/lorem.py
    python examples/mario.py
    python color_test.py

[testenv:docs]
changedir = docs
skip_install = True
basepython = python3
deps = -r{toxinidir}/docs/requirements-docs.txt
commands =
    sphinx-build -W --keep-going -b html . {envtmpdir}/html

[testenv:lint]
skip_install = True
basepython = python3
deps =
    flake8
    pydocstyle
    isort[colors]
commands =
    flake8 colorise tests
    pydocstyle colorise
    isort --check --diff --color colorise tests

[flake8]
max-line-length = 88
extend-ignore = W503

[isort]
line_length = 88
multi_line_output = 3
include_trailing_comma = true
combine_as_imports = true

[tox]
minversion = 2.0
envlist = py{35,36,37,38,39},pypy3

[pytest]
addopts = -rs -v --showlocals
testpaths = tests

[testenv]
passenv = COLORTERM COLORFGBG SHELL TERM TERM_PROGRAM TERM_PROGRAM_VERSION ConEmuANSI
deps = pytest
commands = pytest {posargs}

[testenv:scripts]
commands =
    python examples/autoreset_demo.py
    python examples/colorspaces.py
    python examples/highlight_differences.py
    python examples/humpty.py
    python examples/lorem.py
    python examples/mario.py
    python color_test.py

[testenv:docs]
changedir = docs
skip_install = True
basepython = python3
deps = -r{toxinidir}/docs/requirements-docs.txt
commands =
    sphinx-build -W --keep-going -b html . {envtmpdir}/html

[testenv:lint]
skip_install = True
basepython = python3
deps =
    flake8
    pydocstyle
    isort[colors]
commands =
    flake8 colorise tests
    pydocstyle colorise
    isort --check --diff --color colorise tests

[flake8]
max-line-length = 88
extend-ignore = W503

[isort]
line_length = 88
multi_line_output = 3
include_trailing_comma = true
combine_as_imports = true

Allow positional arguments to pytest
Allow positional arguments to pytest [skip ci]
