You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

57 lines
1.1 KiB

  1. [tox]
  2. requires =
  3. tox-poetry
  4. poetry
  5. envlist = check, apply-check, docs, tests, build, changelog
  6. [testenv]
  7. whitelist_externals =
  8. bash
  9. [testenv:check]
  10. commands =
  11. black --check --diff src/keycloak tests docs
  12. isort -c --df src/keycloak tests docs
  13. flake8 src/keycloak tests docs
  14. codespell src tests docs
  15. [testenv:apply-check]
  16. commands =
  17. black -C src/keycloak tests docs
  18. black src/keycloak tests docs
  19. isort src/keycloak tests docs
  20. [testenv:docs]
  21. extras = docs
  22. commands =
  23. sphinx-build -T -E -W -b html -d _build/doctrees -D language=en ./docs/source _build/html
  24. [testenv:tests]
  25. setenv = file|tox.env
  26. passenv = CONTAINER_HOST
  27. commands =
  28. ./test_keycloak_init.sh "pytest -vv --cov=keycloak --cov-report term-missing {posargs}"
  29. [testenv:build]
  30. deps =
  31. poetry
  32. setenv =
  33. POETRY_VIRTUALENVS_CREATE = false
  34. commands =
  35. poetry build --format sdist
  36. poetry build --format wheel
  37. [testenv:changelog]
  38. setenv = file|tox.env
  39. passenv = CONTAINER_HOST
  40. commands =
  41. cz changelog
  42. [flake8]
  43. max-line-length = 99
  44. docstring-convention = all
  45. ignore = D203, D213, W503
  46. docstring_style = sphinx
  47. [darglint]
  48. enable = DAR104