Bartek Grzybowski | 76c43bf | 2020-02-28 14:09:43 +0100 | [diff] [blame] | 1 | [tox] |
| 2 | minversion = 3.2.0 |
mrichomme | cd33b63 | 2020-04-09 18:38:07 +0200 | [diff] [blame] | 3 | envlist = json,yaml,py,rst,md |
Bartek Grzybowski | 76c43bf | 2020-02-28 14:09:43 +0100 | [diff] [blame] | 4 | skipsdist = true |
| 5 | requires = pip >= 8 |
| 6 | |
| 7 | [testenv] |
Marek Szwałkiewicz | 80ba896 | 2024-08-26 11:57:37 +0200 | [diff] [blame^] | 8 | basepython = python3.8 |
Marek Szwałkiewicz | 0cde237 | 2023-04-13 13:59:29 +0200 | [diff] [blame] | 9 | allowlist_externals = |
Bartek Grzybowski | 76c43bf | 2020-02-28 14:09:43 +0100 | [diff] [blame] | 10 | git |
Marek Szwałkiewicz | 0cde237 | 2023-04-13 13:59:29 +0200 | [diff] [blame] | 11 | sh |
| 12 | /bin/sh |
Bartek Grzybowski | 76c43bf | 2020-02-28 14:09:43 +0100 | [diff] [blame] | 13 | bash |
Marek Szwałkiewicz | 0cde237 | 2023-04-13 13:59:29 +0200 | [diff] [blame] | 14 | /bin/bash |
Bartek Grzybowski | 76c43bf | 2020-02-28 14:09:43 +0100 | [diff] [blame] | 15 | deps = |
| 16 | coala-bears |
mrichomme | cd33b63 | 2020-04-09 18:38:07 +0200 | [diff] [blame] | 17 | nodeenv |
Bartek Grzybowski | 76c43bf | 2020-02-28 14:09:43 +0100 | [diff] [blame] | 18 | |
| 19 | [testenv:json] |
| 20 | commands_pre = |
| 21 | /bin/sh -c "git --no-pager diff HEAD HEAD^ --name-only '*.json' > /tmp/.coalist_json" |
| 22 | commands = |
| 23 | # '\ ' at the end of command is needed for a case where above command returns empty list (it adds empty file |
| 24 | # parameter to '--files' opt |
| 25 | /bin/bash -c "coala --non-interactive --disable-caching --no-autoapply-warn json --files $(</tmp/.coalist_json) \ " |
| 26 | |
| 27 | [testenv:yaml] |
| 28 | commands_pre = |
| 29 | /bin/sh -c "git --no-pager diff HEAD HEAD^ --name-only '*.yaml' '*.yml' > /tmp/.coalist_yaml" |
| 30 | commands = |
| 31 | # '\ ' at the end of command is needed for a case where above command returns empty list (it adds empty file |
| 32 | # parameter to '--files' opt |
| 33 | /bin/bash -c "coala --non-interactive --disable-caching --no-autoapply-warn yaml --files $(</tmp/.coalist_yaml) \ " |
Bartek Grzybowski | 13de1c6 | 2020-03-06 14:20:07 +0100 | [diff] [blame] | 34 | |
| 35 | [testenv:py] |
| 36 | commands_pre = |
| 37 | /bin/sh -c "git --no-pager diff HEAD HEAD^ --name-only '*.py' > /tmp/.coalist_py" |
| 38 | commands = |
| 39 | /bin/bash -c "coala --non-interactive --disable-caching --no-autoapply-warn py --files $(</tmp/.coalist_py) \ " |
mrichomme | cd33b63 | 2020-04-09 18:38:07 +0200 | [diff] [blame] | 40 | |
| 41 | [testenv:rst] |
Cédric Ollivier | d6b0c10 | 2021-09-28 14:17:04 +0200 | [diff] [blame] | 42 | deps = |
| 43 | -r{toxinidir}/docs/requirements-docs.txt |
Cédric Ollivier | 6f35704 | 2021-09-29 16:27:06 +0200 | [diff] [blame] | 44 | -chttps://git.onap.org/doc/plain/etc/upper-constraints.onap.txt |
mrichomme | cd33b63 | 2020-04-09 18:38:07 +0200 | [diff] [blame] | 45 | commands = |
Michal Jagiello | 8f5d154 | 2023-03-24 12:30:38 +0000 | [diff] [blame] | 46 | sphinx-build -W -n -b html docs docs/build/html |
| 47 | sphinx-build -W -n -b linkcheck docs docs/build/linkcheck |
mrichomme | cd33b63 | 2020-04-09 18:38:07 +0200 | [diff] [blame] | 48 | |
| 49 | [testenv:md] |
| 50 | commands_pre = |
| 51 | nodeenv -p --verbose |
| 52 | npm install --global remark-cli |
| 53 | /bin/sh -c "git --no-pager diff HEAD HEAD^ --name-only '*.md' > /tmp/.coalist_md" |
| 54 | commands = |
| 55 | /bin/bash -c "coala --non-interactive --disable-caching --no-autoapply-warn md --files $(</tmp/.coalist_md) \ " |