2 envlist = docs,pep8,pylint,yamllint,ansiblelint,bashate,py27,py36,cover,perm
8 -c{toxinidir}/upper-constraints.txt
9 -chttps://opendev.org/openstack/requirements/raw/branch/stable/rocky/upper-constraints.txt
10 -r{toxinidir}/requirements.txt
11 -r{toxinidir}/test-requirements.txt
12 install_command = pip install {opts} {packages}
13 commands = nosetests --with-xunit \
16 --cover-package=xtesting \
22 basepython = python2.7
24 doc8 README.rst api --ignore-path api/build
25 sphinx-build -W -b html api/ api/build
28 basepython = python2.7
32 basepython = python2.7
33 whitelist_externals = bash
35 pylint --disable=locally-disabled --ignore-imports=y --reports=n xtesting
38 basepython = python2.7
44 yamllint -s {[testenv:yamllint]files}
47 basepython = python2.7
49 ansible-lint ansible/site.yml
52 commands = nosetests xtesting/tests/unit
55 basepython = python2.7
58 commands = bashate {[testenv:bashate]files}
61 basepython = python2.7
62 commands = bandit -r xtesting -x tests -n 5 -ll -s B602
65 basepython = python2.7
67 xtesting/tests/unit/ci
68 xtesting/tests/unit/core
69 xtesting/tests/unit/energy
70 xtesting/tests/unit/utils/test_decorators.py
71 commands = nosetests --with-coverage --cover-tests \
72 --cover-package xtesting.core \
73 --cover-package xtesting.energy \
74 --cover-package xtesting.tests.unit \
75 --cover-package xtesting.utils.decorators \
76 --cover-min-percentage 100 {[testenv:cover]dirs}
79 basepython = python2.7
80 whitelist_externals = bash
81 path=. -not -path './.tox/*' -not -path './.git/*' -not -path './doc/reveal.js/*'
84 find {[testenv:perm]path} \( -type f -not -perm 644 -o -type d -not -perm 755 \) \
85 -exec ls -l \{\} + | grep '.' && exit 1 || exit 0"
87 find {[testenv:perm]path} -exec file \{\} + | grep CRLF && exit 1 || exit 0"