Kubernetes 1.16.0 node label fix
[ta/config-manager.git] / cmdatahandlers / tox.ini
1 [tox]
2 envlist = py27-pytest,pylint
3
4 [testenv]
5 basepython = python2.7
6 changedir = tests
7
8 setenv =
9     PYTHONPATH = {toxinidir}/src
10     COVERAGE_FILE = .coverage{envname}
11
12 passenv = COVERAGE_FILE
13
14 commands = /bin/cp -R {toxinidir}/tests/mocked_dependencies/serviceprofiles {toxworkdir}/py27-pytest/lib/python2.7/site-packages/
15            pytest -vv \
16            --basetemp={envtmpdir} \
17            --pep8 \
18            --cov cmdatahandlers.performance_profiles \
19            --cov-config .coveragerc \
20            --cov-branch \
21            --cov-report term-missing \
22            --cov-report html:htmlcov \
23            {posargs:.}
24
25 deps=
26      pip==10.0.1
27      pytest
28      mock
29      pytest-cov
30      pytest-flakes
31      pytest-pep8
32      netaddr
33      pyyaml
34      jinja2
35      # more-itertools above version 5.0.0 down not support Python 2.7
36      more-itertools==5.0.0
37
38 [pytest]
39 cache_dir = .pytest-cache
40 pep8maxlinelength = 100
41 pep8ignore = src/setup.py ALL
42              src/cmdatahandlers/api/* ALL
43              src/cmdatahandlers/has/* ALL
44              src/cmdatahandlers/hosts/* ALL
45              src/cmdatahandlers/localstorage/* ALL
46              src/cmdatahandlers/network_profiles/* ALL
47              src/cmdatahandlers/networking/* ALL
48              src/cmdatahandlers/openstack/* ALL
49              src/cmdatahandlers/storage_profiles/* ALL
50              src/cmdatahandlers/time/* ALL
51              src/cmdatahandlers/users/* ALL
52              tests/* ALL
53
54 [testenv:pylint]
55 commands = /bin/cp -R {toxinidir}/tests/mocked_dependencies/serviceprofiles {toxworkdir}/pylint/lib/python2.7/site-packages/
56            -pylint --rcfile={toxinidir}/pylintrc {posargs:cmdatahandlers.performance_profiles}
57
58 deps=
59      pip==10.0.1
60      pylint==1.9.2
61      mock