From 2a46b146135aa5694eb9de288c24037051268fdf Mon Sep 17 00:00:00 2001 From: "Kali Kaneko (leap communications)" Date: Thu, 1 Sep 2016 00:09:32 -0400 Subject: [tests] tox configuration --- Makefile | 12 ++++++++++++ setup.cfg | 18 ++++++++++++++++-- tox.ini | 26 ++++++++++++++++++++++++++ 3 files changed, 54 insertions(+), 2 deletions(-) create mode 100644 Makefile diff --git a/Makefile b/Makefile new file mode 100644 index 00000000..43df3700 --- /dev/null +++ b/Makefile @@ -0,0 +1,12 @@ +clean: + find . -type f -name "*.py[co]" -delete + find . -type d -name "__pycache__" -delete + +dev-mail: + pip install -e '.[mail]' + +dev-all: + pip install -e '.[all]' + +uninstall: + pip uninstall leap.bitmask diff --git a/setup.cfg b/setup.cfg index 11464c25..307b08bf 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,10 +1,10 @@ [pep8] exclude = versioneer.py,_version.py,*.egg,build,dist,docs -ignore = E731 +ignore = E731 E402 [flake8] exclude = versioneer.py,_version.py,*.egg,build,dist,docs -ignore = E731 +ignore = E731 E402 [versioneer] VCS = git @@ -12,3 +12,17 @@ style = pep440 versionfile_source = src/leap/bitmask/_version.py versionfile_build = leap/bitmask/_version.py tag_prefix = + +[tool:pytest] +pep8ignore = + * E731 E402 + docs/conf.py ALL + versioneer.py ALL + _version.py ALL + *.egg ALL + +[coverage:run] +branch = True + +[coverage:html] +directory = cov_html diff --git a/tox.ini b/tox.ini index e69de29b..67719391 100644 --- a/tox.ini +++ b/tox.ini @@ -0,0 +1,26 @@ +[tox] +envlist = py27 + +[testenv] +commands = py.test --cov-report=html \ + --cov-report=term \ + --cov=leap.bitmask \ + --pep8 {posargs} +deps = + mock + pep8 + pytest + pytest-pep8 + pytest-cov + setuptools-trial + gnupg + leap.soledad.common + + # move this to another env! + #leap.soledad.client + -e../soledad/client + -e. +setenv = + HOME=/tmp + + -- cgit v1.2.3