summary refs log tree commit diff
path: root/tox.ini
diff options
context:
space:
mode:
authorRichard van der Hoff <richard@matrix.org>2016-12-06 11:35:14 +0000
committerRichard van der Hoff <richard@matrix.org>2016-12-06 11:35:14 +0000
commit7dae7087d3734ea12d97130fab7515c6f604c581 (patch)
tree5e3ad476562c564ac5f6b0b0f579556e7e52dade /tox.ini
parentMerge pull request #1671 from kyrias/fix-preview-test (diff)
downloadsynapse-7dae7087d3734ea12d97130fab7515c6f604c581.tar.xz
Fix unittests under tox
We now need to set PYTHONPATH when running the unit tests; update tox config to
do so.
Diffstat (limited to 'tox.ini')
-rw-r--r--tox.ini7
1 files changed, 7 insertions, 0 deletions
diff --git a/tox.ini b/tox.ini

index 52d93c65e5..39ad305360 100644 --- a/tox.ini +++ b/tox.ini
@@ -8,8 +8,15 @@ deps = mock python-subunit junitxml + + # needed by some of the tests + lxml + setenv = PYTHONDONTWRITEBYTECODE = no_byte_code + # As of twisted 16.4, trial tries to import the tests as a package, which + # means it needs to be on the pythonpath. + PYTHONPATH = {toxinidir} commands = /bin/sh -c "find {toxinidir} -name '*.pyc' -delete ; coverage run {env:COVERAGE_OPTS:} --source={toxinidir}/synapse \ {envbindir}/trial {env:TRIAL_FLAGS:} {posargs:tests} {env:TOXSUFFIX:}"