Sylvain Desbureaux | 3c393e5 | 2020-12-07 09:15:19 +0100 | [diff] [blame] | 1 | [tox] |
| 2 | minversion = 1.6 |
| 3 | envlist = |
Sylvain Desbureaux | ec07bca | 2020-12-09 10:13:42 +0100 | [diff] [blame] | 4 | docs, |
| 5 | docs-linkcheck, |
Sylvain Desbureaux | 3c393e5 | 2020-12-07 09:15:19 +0100 | [diff] [blame] | 6 | gitlint, |
Guillaume Lambert | 85b1492 | 2021-03-12 13:53:18 +0100 | [diff] [blame] | 7 | checkbashisms, |
Sylvain Desbureaux | 3c393e5 | 2020-12-07 09:15:19 +0100 | [diff] [blame] | 8 | skipsdist=true |
| 9 | |
Sylvain Desbureaux | ec07bca | 2020-12-09 10:13:42 +0100 | [diff] [blame] | 10 | [doc8] |
| 11 | ignore-path-errors=docs/helm-search.txt;D001 |
| 12 | |
| 13 | [testenv:doc8] |
| 14 | deps = -rdocs/requirements-docs.txt |
guillaume.lambert | f3319a8 | 2021-09-26 21:37:50 +0200 | [diff] [blame] | 15 | doc8 |
Sylvain Desbureaux | ec07bca | 2020-12-09 10:13:42 +0100 | [diff] [blame] | 16 | commands = |
guillaume.lambert | f3319a8 | 2021-09-26 21:37:50 +0200 | [diff] [blame] | 17 | - doc8 docs/ |
Sylvain Desbureaux | ec07bca | 2020-12-09 10:13:42 +0100 | [diff] [blame] | 18 | |
| 19 | [testenv:docs] |
| 20 | deps = -rdocs/requirements-docs.txt |
| 21 | commands = |
guillaume.lambert | 91df0d8 | 2021-04-24 10:37:53 +0200 | [diff] [blame] | 22 | sphinx-build -q -W -b html -n -d {envtmpdir}/doctrees ./docs/ {toxinidir}/docs/_build/html |
Sylvain Desbureaux | ec07bca | 2020-12-09 10:13:42 +0100 | [diff] [blame] | 23 | |
| 24 | [testenv:docs-linkcheck] |
| 25 | deps = -rdocs/requirements-docs.txt |
guillaume.lambert | 91df0d8 | 2021-04-24 10:37:53 +0200 | [diff] [blame] | 26 | commands = sphinx-build -q -W -b linkcheck -d {envtmpdir}/doctrees ./docs/ {toxinidir}/docs/_build/linkcheck |
Sylvain Desbureaux | ec07bca | 2020-12-09 10:13:42 +0100 | [diff] [blame] | 27 | |
Guillaume Lambert | b825e91 | 2021-02-01 21:22:33 +0100 | [diff] [blame] | 28 | [testenv:spelling] |
| 29 | #basepython = python3 |
| 30 | whitelist_externals = wget |
| 31 | deps = |
| 32 | -rdocs/requirements-docs.txt |
| 33 | sphinxcontrib-spelling |
| 34 | PyEnchant |
| 35 | changedir={toxinidir}/docs |
| 36 | commands = |
Guillaume Lambert | 089ba21 | 2021-02-10 11:48:39 +0100 | [diff] [blame] | 37 | wget -nv https://git.onap.org/doc/plain/docs/spelling_wordlist.txt -O spelling_wordlist.txt |
Guillaume Lambert | b825e91 | 2021-02-01 21:22:33 +0100 | [diff] [blame] | 38 | sphinx-build -b spelling -d {envtmpdir}/doctrees . _build/spelling |
| 39 | |
Sylvain Desbureaux | 3c393e5 | 2020-12-07 09:15:19 +0100 | [diff] [blame] | 40 | [testenv:gitlint] |
| 41 | basepython = python3 |
| 42 | deps = |
| 43 | gitlint |
| 44 | |
| 45 | commands = |
| 46 | gitlint |
| 47 | |
Guillaume Lambert | d8eab71 | 2021-03-08 21:49:28 +0100 | [diff] [blame] | 48 | [testenv:checkbashisms] |
| 49 | deps = |
| 50 | whitelist_externals = sh |
| 51 | find |
| 52 | checkbashisms |
| 53 | commands = |
| 54 | sh -c 'which checkbashisms>/dev/null || sudo yum install devscripts-minimal || sudo apt-get install devscripts \ |
| 55 | || (echo "checkbashisms command not found - please install it (e.g. sudo apt-get install devscripts | \ |
| 56 | yum install devscripts-minimal )" >&2 && exit 1)' |
Guillaume Lambert | 85b1492 | 2021-03-12 13:53:18 +0100 | [diff] [blame] | 57 | find . -not -path '*/\.*' -name *.sh -exec checkbashisms \{\} + |
Guillaume Lambert | d8eab71 | 2021-03-08 21:49:28 +0100 | [diff] [blame] | 58 | |
Guillaume Lambert | 056b2d4 | 2021-02-17 12:09:47 +0100 | [diff] [blame] | 59 | [testenv:autopep8] |
| 60 | deps = autopep8 |
| 61 | commands = |
| 62 | autopep8 --max-line-length 120 --in-place --recursive kubernetes/ TOSCA/ docs/ |
| 63 | |
| 64 | [testenv:pylint] |
| 65 | deps = pylint |
| 66 | whitelist_externals = find |
| 67 | commands = |
| 68 | find kubernetes/ TOSCA/ docs/ -name *.py -exec pylint --max-line-length=120 --disable=missing-docstring --method-rgx="(([a-z_][a-zA-Z0-9_]{2,})|(_[a-z0-9_]*)|(__[a-zA-Z][a-zA-Z0-9_]+__))$" --variable-rgx="[a-zA-Z_][a-zA-Z0-9_]{1,30}$" --reports=y --score=y --output-format=colorized \{\} + |
| 69 | |