Fix provisoner timeout
[osm/N2VC.git] / tox.ini
diff --git a/tox.ini b/tox.ini
index 350a1fc..481bb9d 100644 (file)
--- a/tox.ini
+++ b/tox.ini
@@ -4,7 +4,7 @@
 # and then run "tox" from this directory.
 
 [tox]
-envlist = lint,py3
+envlist = py3,lint,integration
 skipsdist=True
 
 [pytest]
@@ -14,53 +14,49 @@ markers =
 [testenv]
 basepython=python3
 usedevelop=True
+
 # for testing with other python versions
-commands = py.test --tb native -ra -v -s -n auto -k 'not integration' -m 'not serial' {posargs}
+commands = py.test --ignore modules/ --ignore tests/charms/ --tb native -ra -v -s -n auto -k 'not integration' -m 'not serial' {posargs}
 passenv =
     HOME
-    TEST_AGENTS
+    VCA_PATH
+    VCA_HOST
+    VCA_PORT
+    VCA_USER
+    VCA_SECRET
+    LXD_HOST
+    LXD_SECRET
+    # These are needed so executing `charm build` succeeds
+    TERM
+    TERMINFO
 deps =
-    asynctest
-    ipdb
     mock
+    pyyaml
     pytest
     pytest-asyncio
     pytest-xdist
-    Twine
-    # use fork to pick up fix for https://github.com/aaugustin/websockets/pull/528
-    git+https://github.com/johnsca/websockets@bug/client-redirects#egg=websockets
+    pytest-assume
+    paramiko
+    pylxd
 
 [testenv:py3]
-# default tox env excludes integration and serial tests
+# default tox env, excludes integration and serial tests
 commands =
-    # These need to be installed in a specific order
-    pip install urllib3==1.22
-    pip install pylxd
-    py.test --tb native -ra -v -s -n auto -k 'not integration' -m 'not serial' {posargs}
+    pytest --ignore modules/ --ignore tests/charms/ --tb native -ra -v -s -n auto -k 'not integration' -m 'not serial' {posargs}
 
 [testenv:lint]
 envdir = {toxworkdir}/py3
 commands =
-    flake8 --ignore E501,W504 {posargs} juju tests
+    flake8 --ignore E501,E402 --exclude tests/charms/builds,tests/charms/deps {posargs} n2vc tests
 deps =
     flake8
 
 [testenv:integration]
 envdir = {toxworkdir}/py3
-commands =
-    # These need to be installed in a specific order
-    pip install urllib3==1.22
-    pip install pylxd
-    py.test --tb native -ra -v -s -n auto -k 'integration' -m 'not serial' {posargs}
-
-[testenv:serial]
-# tests that can't be run in parallel
-envdir = {toxworkdir}/py3
-commands = py.test --tb native -ra -v -s {posargs:-m 'serial'}
+commands = py.test --ignore modules/  --ignore tests/charms/ --tb native -ra -v -s -n 1 -k 'integration' -m 'serial' {posargs}
 
-[testenv:example]
-envdir = {toxworkdir}/py3
-commands = python {posargs}
-
-[flake8]
-exclude = juju/client/_*
+[testenv:build]
+deps =
+    stdeb
+    setuptools-version-command
+commands = python3 setup.py --command-packages=stdeb.command bdist_deb