Clean-up tox.ini
* move ostestr execution to [testenv] * effectively enable `lower-constraints` job execution * use default configuration for `py36` environment Change-Id: Id8f914b5a7f4cbc996238c5c4f2b1f352b901e5d
This commit is contained in:
parent
c372a9b412
commit
8fbdb9423a
30
tox.ini
30
tox.ini
|
@ -19,33 +19,12 @@ deps =
|
|||
-r{toxinidir}/requirements.txt
|
||||
commands =
|
||||
find ./ -type f -name '*.pyc' -delete
|
||||
|
||||
[testenv:py27]
|
||||
description = Runs unit test using Python2.7
|
||||
basepython = python2.7
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
stestr run {posargs}
|
||||
|
||||
[testenv:py35]
|
||||
description = Runs unit test using Python3.5
|
||||
basepython = python3.5
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
stestr run {posargs}
|
||||
|
||||
[testenv:py36]
|
||||
description = Runs unit test using Python3.6
|
||||
basepython = python3.6
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
stestr run {posargs}
|
||||
|
||||
[testenv:cover]
|
||||
description = Calculates code coverage
|
||||
basepython = python2.7
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
coverage erase
|
||||
python setup.py test --coverage --testr-args='{posargs}' --coverage-package-name=monasca_log_api
|
||||
coverage report
|
||||
|
@ -54,7 +33,6 @@ commands =
|
|||
basepython = python3
|
||||
description = Allows to run unit-test with debug mode enabled
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
oslo_debug_helper -t {toxinidir}/monasca_log_api/tests {posargs}
|
||||
|
||||
[testenv:bashate]
|
||||
|
@ -77,7 +55,6 @@ commands =
|
|||
basepython = python3
|
||||
description = Runs set of linters against codebase (flake8, bandit, bashate, checkniceness)
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
{[testenv:flake8]commands}
|
||||
{[testenv:bandit]commands}
|
||||
{[testenv:bashate]commands}
|
||||
|
@ -87,7 +64,6 @@ commands =
|
|||
basepython = python3
|
||||
description = Validates codebase with flake
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
flake8 monasca_log_api
|
||||
|
||||
[testenv:genconfig]
|
||||
|
@ -99,7 +75,6 @@ commands = oslo-config-generator --config-file=config-generator/monasca-log-api.
|
|||
basepython = python3
|
||||
description = Builds api-ref, api-guide, releasenotes and devdocs
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
{[testenv:devdocs]commands}
|
||||
{[testenv:api-guide]commands}
|
||||
{[testenv:api-ref]commands}
|
||||
|
@ -109,7 +84,6 @@ commands =
|
|||
basepython = python3
|
||||
description = Called from CI scripts to test and publish the API Guide
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
rm -rf api-guide/build
|
||||
{[testenv:checkjson]commands}
|
||||
sphinx-build -W -b html -d api-guide/build/doctrees api-guide/source api-guide/build/html
|
||||
|
@ -118,7 +92,6 @@ commands =
|
|||
basepython = python3
|
||||
description = Called from CI scripts to test and publish the API Ref
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
rm -rf api-ref/build
|
||||
{[testenv:checkjson]commands}
|
||||
sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
|
||||
|
@ -134,7 +107,6 @@ commands =
|
|||
basepython = python3
|
||||
description = Builds developer documentation
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
rm -rf doc/build
|
||||
rm -rf doc/source/contributor/api
|
||||
{[testenv:checkjson]commands}
|
||||
|
@ -146,7 +118,6 @@ description = Validates (pep-like) documenation
|
|||
skip_install = True
|
||||
usedevelop = False
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
doc8 --file-encoding utf-8 {toxinidir}/doc
|
||||
doc8 --file-encoding utf-8 {toxinidir}/api-ref
|
||||
doc8 --file-encoding utf-8 {toxinidir}/api-guide
|
||||
|
@ -164,7 +135,6 @@ whitelist_externals =
|
|||
find
|
||||
rm
|
||||
commands =
|
||||
{[testenv]commands}
|
||||
bash -c "! find doc/ -type f -name *.json | xargs grep -U -n $'\r'"
|
||||
bash -c '! find doc/ -type f -name *.json | xargs -t -n1 python -m json.tool 2>&1 > /dev/null | grep -B1 -v ^python'
|
||||
|
||||
|
|
Loading…
Reference in New Issue