-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy path.travis.yml
More file actions
46 lines (42 loc) · 1.65 KB
/
.travis.yml
File metadata and controls
46 lines (42 loc) · 1.65 KB
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# run the testsuite on travis-ci.com
---
# versions to run on
env:
- PG_SUPPORTED_VERSIONS=9.4
- PG_SUPPORTED_VERSIONS=9.5
- PG_SUPPORTED_VERSIONS=9.6
- PG_SUPPORTED_VERSIONS=10
language: C
dist: trusty
sudo: required
before_install:
# apt.postgresql.org is already configured, we just need to add devel
- |
DIST=trusty-pgdg
if [ "$PG_SUPPORTED_VERSIONS" = "10" ]; then
# update pgdg-source.list
sudo sed -i -e "s/pgdg.*/pgdg-testing main $PG_SUPPORTED_VERSIONS/" /etc/apt/sources.list.d/pgdg*.list
DIST=trusty-pgdg-testing
fi
- sudo apt-get -qq update
install:
- export DEBIAN_FRONTEND=noninteractive # suppress warnings about deprecated PostgreSQL versions
# trusty's pg_buildext doesn't cope with PG version numbers >= 10, so upgrade that to -pgdg
- sudo apt-get install debhelper devscripts fakeroot postgresql-server-dev-$PG_SUPPORTED_VERSIONS postgresql-server-dev-all/$DIST
# install PostgreSQL $PG_SUPPORTED_VERSIONS if not there yet
- |
if [ ! -x /usr/lib/postgresql/$PG_SUPPORTED_VERSIONS/bin/postgres ]; then
sudo apt-get install postgresql-common # upgrade pg-common first ...
sudo /etc/init.d/postgresql stop # ... so we can stop postgresql again before installing the server
sudo apt-get install postgresql-$PG_SUPPORTED_VERSIONS
fi
# stop the travis-provided cluster
- sudo /etc/init.d/postgresql stop
- pg_lsclusters
- dpkg -l postgresql\* | cat
script:
- pg_buildext updatecontrol
- dpkg-buildpackage -us -uc -rfakeroot
- for deb in ../*.deb; do echo "$deb:"; dpkg-deb --info $deb; dpkg-deb --contents $deb; done
- sudo debi
- pg_buildext -i '--locale=C.UTF-8' installcheck