File: tox.ini

package info (click to toggle)
python-tooz 8.1.0-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 940 kB
  • sloc: python: 5,945; sh: 158; makefile: 27
file content (77 lines) | stat: -rw-r--r-- 2,251 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
[tox]
minversion = 3.18.0
envlist = py3,py{310,313}-{zookeeper,redis,sentinel,memcached,postgresql,mysql,consul,etcd,etcd3gw,kubernetes},pep8

[testenv]
deps =
    -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
    -r{toxinidir}/requirements.txt
    -r{toxinidir}/test-requirements.txt
setenv =
    TOOZ_TEST_URLS = file:///tmp ipc://
    zookeeper: TOOZ_TEST_DRIVERS = zookeeper
    redis: TOOZ_TEST_DRIVERS = redis
    sentinel: TOOZ_TEST_DRIVERS = redis --sentinel
    sentinel: TOOZ_TEST_SENTINEL = 1
    memcached: TOOZ_TEST_DRIVERS = memcached
    mysql: TOOZ_TEST_DRIVERS = mysql
    postgresql: TOOZ_TEST_DRIVERS = postgresql
    etcd: TOOZ_TEST_DRIVERS = etcd,etcd --cluster
    etcd3gw: TOOZ_TEST_DRIVERS = etcd
    etcd3gw: TOOZ_TEST_ETCD3GW = 1
    consul: TOOZ_TEST_DRIVERS = consul
    kubernetes: TOOZ_TEST_DRIVERS = kubernetes
allowlist_externals =
    {toxinidir}/run-tests.sh
commands =
    {toxinidir}/run-tests.sh stestr run "{posargs}"
passenv =
    ETCD_VERSION

[testenv:venv]
# This target is used by the gate go run Sphinx to build the doc
deps = {[testenv:docs]deps}
commands = {posargs}

[testenv:examples]
allowlist_externals =
    {toxinidir}/run-examples.sh
commands =
    {toxinidir}/run-examples.sh

[testenv:cover]
deps = {[testenv]deps}
setenv = {[testenv]setenv}
    PYTHON=coverage run --source tooz --parallel-mode
commands =
    coverage erase
    {toxinidir}/run-tests.sh stestr run "{posargs}"
    coverage combine
    coverage html -d cover
    coverage xml -o cover/coverage.xml
    coverage report --show-missing

[testenv:docs]
deps =
    -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
    -r{toxinidir}/doc/requirements.txt
commands =
    sphinx-build -W -b html doc/source doc/build/html

[testenv:releasenotes]
deps = {[testenv:docs]deps}
commands =
    sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html

[testenv:pep8]
skip_install = true
deps =
    pre-commit
commands =
    pre-commit run --all-files --show-diff-on-failure

[flake8]
# We only enable the hacking (H) checks
select = H
show-source = true
exclude = .venv,.git,.tox,dist,*egg,*.egg-info,build,examples,doc