Accept None for parameter ca_cert at vnf.py: N2VC.__init__
[osm/N2VC.git] / modules / libjuju / tox.ini
1 # Tox (http://tox.testrun.org/) is a tool for running tests
2 # in multiple virtualenvs. This configuration file will run the
3 # test suite on all supported python versions. To use it, "pip install tox"
4 # and then run "tox" from this directory.
5
6 [tox]
7 envlist = lint,py3
8 skipsdist=True
9
10 [pytest]
11 markers =
12 serial: mark a test that must run by itself
13
14 [testenv]
15 basepython=python3
16 usedevelop=True
17 # for testing with other python versions
18 commands = py.test --tb native -ra -v -s -n auto -k 'not integration' -m 'not serial' {posargs}
19 passenv =
20 HOME
21 TEST_AGENTS
22 deps =
23 asynctest
24 ipdb
25 mock
26 pytest
27 pytest-asyncio
28 pytest-xdist
29 Twine
30 # use fork to pick up fix for https://github.com/aaugustin/websockets/pull/528
31 git+https://github.com/johnsca/websockets@bug/client-redirects#egg=websockets
32
33 [testenv:py3]
34 # default tox env excludes integration and serial tests
35 commands =
36 # These need to be installed in a specific order
37 pip install urllib3==1.22
38 pip install pylxd
39 py.test --tb native -ra -v -s -n auto -k 'not integration' -m 'not serial' {posargs}
40
41 [testenv:lint]
42 envdir = {toxworkdir}/py3
43 commands =
44 flake8 --ignore E501,W504 {posargs} juju tests
45 deps =
46 flake8
47
48 [testenv:integration]
49 envdir = {toxworkdir}/py3
50 commands =
51 # These need to be installed in a specific order
52 pip install urllib3==1.22
53 pip install pylxd
54 py.test --tb native -ra -v -s -n auto -k 'integration' -m 'not serial' {posargs}
55
56 [testenv:serial]
57 # tests that can't be run in parallel
58 envdir = {toxworkdir}/py3
59 commands = py.test --tb native -ra -v -s {posargs:-m 'serial'}
60
61 [testenv:example]
62 envdir = {toxworkdir}/py3
63 commands = python {posargs}
64
65 [flake8]
66 exclude = juju/client/_*