Skip to content

Commit

Permalink
Update test matrix removing Python 3.4 and adding 3.6, 3.7, 3.8
Browse files Browse the repository at this point in the history
Python 3.4 is now EOL.

Update to Xenial required for Python 3.7 and 3.8 on Travis.

Update flake8 to use Python 3.8 compatible pyflakes [1]. Allow the
latest matching pycodestyle to be automatically installed.

Use libsqlite3-mod-spatialite to save compile time.

[1] PyCQA/pyflakes#367
  • Loading branch information
cjmayo committed Mar 14, 2020
1 parent 2cadea8 commit 8cfbb70
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 47 deletions.
30 changes: 13 additions & 17 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
language: python

sudo: true
dist: trusty
dist: xenial

addons:
postgresql: 9.3
postgresql: 9.6
apt:
packages:
- postgresql-9.3-postgis-2.3
- postgresql-9.6-postgis-2.4
- python2.7-dev
- python3-dev
- autotools-dev
Expand All @@ -17,6 +17,7 @@ addons:
- libproj-dev
- libreadline-dev
- libsqlite3-dev
- libsqlite3-mod-spatialite
- libxml2-dev
- zlib1g-dev

Expand All @@ -27,33 +28,28 @@ notifications:
services:
- postgresql

cache:
directories:
- libspatialite-4.3.0a

matrix:
include:
- python: 2.7
env:
- TOX_ENV=py27sqla11
- python: 3.4
env:
- TOX_ENV=py34sqla11
- python: 3.5
env:
- TOX_ENV=py35sqla11
- python: 3.6
env:
- TOX_ENV=py36sqla11
- python: 3.7
env:
- TOX_ENV=py37sqla11
- python: 3.8
env:
- TOX_ENV=py38sqla11
- python: pypy
env:
- TOX_ENV=pypysqla11

env:
global:
- SPATIALITE_LIBRARY_PATH="/usr/local/lib/mod_spatialite.so"

install:
# Install Spatialite
- ./install-spatialite.sh

# Install tox
- pip install tox

Expand Down
20 changes: 0 additions & 20 deletions install-spatialite.sh

This file was deleted.

3 changes: 1 addition & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@
-e .

# Additional requirements for running the testsuite and development
pycodestyle==2.2.0
flake8==3.2.0
flake8==3.7.9
pytest==3.7.4
pytest-cov==2.5.1

Expand Down
29 changes: 21 additions & 8 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
[tox]
envlist=py27sqla11, py34sqla11, py35sqla11, pypysqla11
envlist=py27sqla11, py35sqla11, py36sqla11, py37sqla11, py38sqla11, pypysqla11

[testenv]
passenv=SPATIALITE_LIBRARY_PATH
commands=
py.test \
{posargs}
Expand All @@ -15,23 +14,37 @@ deps=
pysqlite
-rrequirements.txt

[testenv:py34sqla11]
basepython=python3.4
[testenv:py35sqla11]
basepython=python3.5
deps=
SQLAlchemy==1.1.2
psycopg2
-rrequirements.txt

[testenv:py35sqla11]
basepython=python3.5
[testenv:py36sqla11]
basepython=python3.6
deps=
SQLAlchemy==1.1.2
psycopg2
-rrequirements.txt

[testenv:pypysqla11]
basepython=pypy
[testenv:py37sqla11]
basepython=python3.7
deps=
SQLAlchemy==1.1.2
psycopg2
-rrequirements.txt

[testenv:py38sqla11]
basepython=python3.8
deps=
SQLAlchemy==1.1.2
psycopg2
-rrequirements.txt

[testenv:pypysqla11]
basepython=pypy3
deps=
SQLAlchemy==1.3.15
psycopg2cffi
-rrequirements.txt

0 comments on commit 8cfbb70

Please sign in to comment.