Tools used by OpenStack Documentation
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.

tox.ini 2.3KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. [tox]
  2. minversion = 2.0
  3. envlist = py27,py37,pep8
  4. skipsdist = True
  5. [testenv]
  6. usedevelop = True
  7. install_command = pip install {opts} {packages}
  8. # Install also sitemap scraping tool, not installed by default
  9. # therefore not in requirements file
  10. deps = scrapy>=1.0.0
  11. -c{env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/branch/master/upper-constraints.txt}
  12. -r{toxinidir}/test-requirements.txt
  13. -r{toxinidir}/requirements.txt
  14. commands = stestr run --slowest {posargs}
  15. [testenv:pep8]
  16. basepython = python3
  17. commands =
  18. flake8
  19. # Run doc8 to check .rst and .txt files.
  20. # HACKING.rst is the only file that is not referenced from
  21. # doc/source, so add it explicitly.
  22. doc8 -e txt -e rst doc/source/ HACKING.rst
  23. # Run bashate during pep8 runs to ensure violations are caught by
  24. # the check and gate queues.
  25. bashate bin/doc-tools-check-languages bin/doc-tools-build-rst
  26. [testenv:releasenotes]
  27. basepython = python3
  28. commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
  29. [testenv:sitemap]
  30. # commands = functional test command goes here
  31. [testenv:venv]
  32. basepython = python3
  33. commands = {posargs}
  34. [testenv:docs]
  35. basepython = python3
  36. commands =
  37. sphinx-build -W -b html -d doc/build/doctrees doc/source doc/build/html
  38. [testenv:bindep]
  39. # Do not install any requirements. We want this to be fast and work even if
  40. # system dependencies are missing, since it's used to tell you what system
  41. # dependencies are missing! This also means that bindep must be installed
  42. # separately, outside of the requirements files, and develop mode disabled
  43. # explicitly to avoid unnecessarily installing the checked-out repo too (this
  44. # further relies on "tox.skipsdist = True" above).
  45. basepython = python3
  46. deps = bindep
  47. commands = bindep test
  48. usedevelop = False
  49. [flake8]
  50. show-source = True
  51. builtins = _
  52. exclude=.venv,.git,.tox,dist,*lib/python*,*egg,build,doc/source/conf.py
  53. # 28 is currently the most complex thing we have
  54. max-complexity=29
  55. ignore = H101
  56. [testenv:lower-constraints]
  57. basepython = python3
  58. # Install also sitemap scraping tool, not installed by default
  59. # therefore not in requirements file
  60. deps =
  61. scrapy>=1.0.0
  62. -c{toxinidir}/lower-constraints.txt
  63. -r{toxinidir}/test-requirements.txt
  64. -r{toxinidir}/requirements.txt