Ctrl K
ComunidadGuías…

tox.ini

Rama master · réplica de lectura del repositorio original.

Archivo original ↗Preguntar a KiBot
[tox]
envlist = py311,py312,py313,py314,py315,pylint,flake8

[flake8]
max-line-length = 139
exclude =
    .tox
    build
    venv
ignore =
    # C901 func is too complex
    C901,
    # E126 continuation line over-indented for hanging indent
    E126,
    # E127 continuation line over-indented for visual indent
    E127,
    # E226 missing whitespace around arithmetic operator
    E226,
    # E231 missing whitespace after ','
    E231,
    # E302 expected 2 blank lines, found 1
    E302,
    # E305 expected 2 blank lines after class or function definition, found 1
    E305,
    # E731 do not assign a lambda expression, use a def
    E731,
    # W292 no newline at end of file
    W292,
    # W504 line break after binary operator
    W504,
    # E203 whitespace before :
    E203,

[pytest]
timeout = 10
timeout_method = thread
markers =
  non_tox: not run on tox
  slow: slow tests
  gui: GUI (functional) tests

[testenv]
usedevelop = true
dependency_groups = tests
; Tox installs groups first, which misinterprets our self-referential extras
; Workaround by installing all extras manually: https://github.com/tox-dev/tox/issues/3561
extras = server,locales

[testenv:py311]
commands =
    pytest --cov buku -vv -m "not non_tox" {posargs}

[testenv:py312]
commands =
    pytest --cov buku -vv -m "not non_tox" {posargs}

[testenv:py313]
commands =
    pytest --cov buku -vv -m "not non_tox" {posargs}

[testenv:py314]
commands =
    pytest --cov buku -vv -m "not non_tox" {posargs}

[testenv:py315]
commands =
    pytest --cov buku -vv -m "not non_tox" {posargs}

[testenv:quick]
basepython = {env:BASEPYTHON:py314}
commands =
    pytest --cov buku -vv -m "not non_tox and not slow" {posargs}

[testenv:nogui]
basepython = {env:BASEPYTHON:py314}
commands =
    pytest --cov buku -vv -m "not non_tox and not gui" {posargs}

[testenv:pylint]
basepython = {env:BASEPYTHON:py314}
commands =
    pylint . --rc-file tests/.pylintrc --recursive yes --ignore-paths .tox/,build/,venv/

[testenv:flake8]
basepython = {env:BASEPYTHON:py314}
commands =
    python -m flake8