Add initial code
[ta/build-tools.git] / tox.ini
diff --git a/tox.ini b/tox.ini
new file mode 100644 (file)
index 0000000..80cf235
--- /dev/null
+++ b/tox.ini
@@ -0,0 +1,35 @@
+[tox]
+envlist = py27, pylint
+skipsdist=true
+
+[testenv]
+commands = py.test -v \
+            --basetemp={toxinidir}/.pytest-tmpdir \
+            --junitxml=junit.xml \
+            --pep8 \
+            --cov-config {toxinidir}/.coveragerc \
+            --cov-branch \
+            --cov-report term-missing \
+            --cov-report html:htmlcov \
+            --cov=. \
+            {posargs:.}
+
+setenv =
+    PYTHONPATH = {toxinidir}/tests/mocked_dependencies:{toxinidir}/src
+deps=-rrequirements.txt
+
+[pytest]
+cache_dir = .pytest-cache
+pep8maxlinelength = 100
+
+[testenv:pylint]
+basepython = python2.7
+commands = pylint --rcfile={toxinidir}/pylintrc {posargs:tools/}
+
+deps=pylint < 2.0
+     -rrequirements.txt
+
+[testenv:clean]
+deps=
+whitelist_externals = rm
+commands = rm -rf .coverage .pytest-cache .pytest-tmpdir junit.xml htmlcov