File: tox.ini

package info (click to toggle)
senlin 6.0.0-1
  • links: PTS, VCS
  • area: main
  • in suites: buster, sid
  • size: 6,872 kB
  • sloc: python: 66,932; sh: 588; makefile: 196
file content (108 lines) | stat: -rw-r--r-- 2,854 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
[tox]
minversion = 1.6
envlist = py35,py27,pep8,functional
skipsdist = True

[testenv]

# Note the hash seed is set to 0 until senlin can be tested with a
# random hash seed successfully.
setenv = VIRTUAL_ENV={envdir}
         OS_TEST_PATH=senlin/tests/unit

deps = -r{toxinidir}/test-requirements.txt

usedevelop = True
install_command = pip install -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} {opts} {packages}
commands =
    find . -type f -name "*.py[c|o]" -delete
    stestr run '{posargs}'
    stestr slowest

whitelist_externals = bash
                      find
                      rm

[testenv:debug]
basepython = python3
commands = oslo_debug_helper -t senlin/tests/unit {posargs}

[testenv:debug-py27]
basepython = python2.7
commands = oslo_debug_helper -t senlin/tests/unit {posargs}

[testenv:debug-py35]
basepython = python3.5
commands = oslo_debug_helper -t senlin/tests/unit {posargs}

[testenv:pep8]
basepython = python3
commands =
    flake8 senlin

[testenv:genconfig]
basepython = python3
envdir = {toxworkdir}/venv
commands =
  {toxinidir}/tools/gen-config

[testenv:genpolicy]
basepython = python3
envdir = {toxworkdir}/venv
commands =
  {toxinidir}/tools/gen-policy

[testenv:venv]
basepython = python3
commands = {posargs}

[testenv:cover]
basepython = python3
setenv =
    {[testenv]setenv}
    PYTHON=coverage run --source senlin --parallel-mode
commands = {toxinidir}/tools/cover.sh {posargs}

[testenv:docs]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
commands =
  sphinx-build -W -b html doc/source doc/build/html

whitelist_externals = rm

[testenv:releasenotes]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html

[testenv:api-ref]
basepython = python3
commands =
  sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html

[flake8]
# Temporarily disable complaints about docstring for public module/class/method
# H106 Don't put vim configuration in source files
# H203 Use assertIs(Not)None to check for None
ignore = D100,D101,D102,D103,D104,D105,D200,D201,D202,D204,D205,D300,D301,D400,D401,I100,I201
enable-extensions=H106,H203,H204,H205
show-source = true
exclude=.venv,.git,.tox,cover,dist,*lib/python*,*egg,tools,build,releasenotes
max-complexity=20

[hacking]
local-check-factory = senlin.hacking.checks.factory
import_exceptions = senlin.common.i18n

[testenv:bandit]
basepython = python3
deps = -r{toxinidir}/test-requirements.txt
commands = bandit -r senlin -x tests -s B101,B104,B110,B310,B311,B506

[testenv:lower-constraints]
basepython = python3
deps =
  -c{toxinidir}/lower-constraints.txt
  -r{toxinidir}/test-requirements.txt
  -r{toxinidir}/requirements.txt