Fix the objref issue.
[pti/o2.git] / tox.ini
1 # content of: tox.ini , put in same dir as setup.py
2 [tox]
3 envlist=
4     flake8,
5     code,
6     docs,
7     docs-linkcheck,
8
9 minversion = 2.0
10 skipsdist = True
11
12 [testenv]
13 basepython =
14     code: python3.8
15     flake8: python3.8
16 setenv =
17         VIRTUAL_ENV={envdir}
18
19 # NOTE: relative paths were used due to '-w' flag for nosetests util
20
21 usedevelop = True
22 install_command = pip install -U {opts} {packages}
23 deps = -r{toxinidir}/requirements.txt
24        -r{toxinidir}/requirements-test.txt
25 whitelist_externals = bash, flake8, pytest
26
27 [testenv:clm]
28 # use pip to report dependencies with versions
29 whitelist_externals = sh
30 commands = sh -c 'pip freeze > requirements.txt'
31
32 [testenv:flake8]
33 commands =
34     flake8 o2ims
35     flake8 o2dms
36     flake8 o2common
37
38 [testenv:code]
39 setenv =
40         O2APP_CONFIG=configs/o2app.conf
41         ALARM_YAML=configs/alarm.yaml
42 commands =
43     pytest tests/unit
44
45 [testenv:nosetests]
46 commands =
47     pytest tests/unit
48
49
50 [testenv:docs]
51 basepython = python3
52 deps =
53     sphinx
54     sphinx-rtd-theme
55     sphinxcontrib-httpdomain
56     recommonmark
57     lfdocs-conf
58
59 commands =
60     sphinx-build -W -b html -n -d {envtmpdir}/doctrees ./docs/ {toxinidir}/docs/_build/html
61
62     echo "Generated docs available in {toxinidir}/docs/_build/html"
63
64 whitelist_externals = echo
65
66 [testenv:docs-linkcheck]
67 basepython = python3
68 deps = sphinx
69        sphinx-rtd-theme
70        sphinxcontrib-httpdomain
71        recommonmark
72        lfdocs-conf
73 commands = sphinx-build -W -b linkcheck -d {envtmpdir}/doctrees ./docs/ {toxinidir}/docs/_build/linkcheck