diff options
Diffstat (limited to '')
-rw-r--r-- | tox.ini | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/tox.ini b/tox.ini index 1a3489344f..1bcd8b627f 100644 --- a/tox.ini +++ b/tox.ini @@ -101,7 +101,7 @@ usedevelop=true # A test suite for the oldest supported versions of Python libraries, to catch # any uses of APIs not available in them. -[testenv:py35-old] +[testenv:py35-{old,old-postgres}] skip_install=True deps = # Ensure a version of setuptools that supports Python 3.5 is installed. @@ -114,11 +114,17 @@ deps = coverage coverage-enable-subprocess==1.0 +setenv = + postgres: SYNAPSE_POSTGRES = 1 + commands = # Make all greater-thans equals so we test the oldest version of our direct # dependencies, but make the pyopenssl 17.0, which can work against an # OpenSSL 1.1 compiled cryptography (as older ones don't compile on Travis). - /bin/sh -c 'python -m synapse.python_dependencies | sed -e "s/>=/==/g" -e "s/psycopg2==2.6//" -e "s/pyopenssl==16.0.0/pyopenssl==17.0.0/" | xargs -d"\n" pip install' + # + # Also strip out psycopg2 unless we need it. + /bin/sh -c 'python -m synapse.python_dependencies | sed -e "s/>=/==/g" -e "/psycopg2/d" -e "s/pyopenssl==16.0.0/pyopenssl==17.0.0/" | xargs -d"\n" pip install' + postgres: /bin/sh -c 'python -m synapse.python_dependencies | sed -e "s/>=/==/g" | grep -F "psycopg2" | xargs -d"\n" pip install' # Install Synapse itself. This won't update any libraries. pip install -e ".[test]" |