forked from openaddresses/machine
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
30 lines (30 loc) · 1.32 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
language: python
python:
- "2.7"
- "3.3"
cache:
apt: true
addons:
postgresql: "9.3"
before_install:
# Although we include chef, we need to pre-install a number of dependencies
# to adapt to Travis Ubuntu apt sources and virtualenv environment.
# https://github.com/travis-ci/travis-ci/issues/2683#issuecomment-52720150
# https://github.com/travis-ci/travis-ci/issues/2938
- sudo apt-get update -y
- sudo apt-get install -y -qq libgdal1h proj gmsh gmt
- sudo apt-get install -y -qq libgdal1-dev python3-dev python-dev
- sudo apt-get install -y -qq libffi-dev libcairo2
install:
# Determine GDAL library version and install a compatible python binding.
# http://gis.stackexchange.com/questions/28966/python-gdal-package-missing-header-file-when-installing-via-pip
- V=`dpkg -s libgdal1-dev | grep Version | cut -d' ' -f2 | cut -d'-' -f1`; env CPLUS_INCLUDE_PATH=/usr/include/gdal C_INCLUDE_PATH=/usr/include/gdal pip install "GDAL==$V"
#
# cairocffi is a drop-in replacement for Pycairo, which is absent from pip.
# http://stackoverflow.com/questions/11491268/install-pycairo-in-virtualenv
# https://pythonhosted.org/cairocffi/
- pip install cairocffi
- sudo chef/run.sh testing
- pip install -U .
env: DATABASE_URL=postgres://openaddr:openaddr@localhost/openaddr
script: python setup.py test