language: python
sudo: false

addons:
  postgresql: "9.6"

python:
 - 3.4
 - 3.5
 - 3.6

env:
 - DJANGO_VERSION=1.11.16
 - DJANGO_VERSION=2.0.9
 - DJANGO_VERSION=2.1.3

matrix:
  exclude:
    - python: 3.4
      env: DJANGO_VERSION=2.1.3

install:
 - pip install -q -r requirements/base.txt
 - pip install -q -r requirements/tests.txt
 - pip install -q django==$DJANGO_VERSION
 - pip install coveralls

before_script:
 - createdb -E UTF-8 dash -U postgres -O $USER

script:
 - coverage run manage.py test --settings=test_runner.settings_travis --verbosity=2 --noinput
 - flake8

after_success:
 - coveralls

language: python
sudo: true

addons:
  postgresql: '10'
  apt:
    packages:
      - postgresql-10
      - postgresql-client-10

python:
 - 3.4
 - 3.5
 - 3.6

env:
 - DJANGO_VERSION=1.11.18
 - DJANGO_VERSION=2.0.10
 - DJANGO_VERSION=2.1.5

matrix:
  exclude:
    - python: 3.4
      env: DJANGO_VERSION=2.1.5

before_install:
  - sudo sed -i -e '/local.*peer/s/postgres/all/' -e 's/peer\|md5/trust/g' /etc/postgresql/*/main/pg_hba.conf
  - sudo sed -i 's/port = 5433/port = 5432/' /etc/postgresql/10/main/postgresql.conf
  - sudo service postgresql restart 10

install:
 - pip install -q -r requirements/base.txt
 - pip install -q -r requirements/tests.txt
 - pip install -q django==$DJANGO_VERSION
 - pip install coveralls

before_script:
 - createdb -E UTF-8 dash -U postgres -O $USER

script:
 - coverage run manage.py test --settings=test_runner.settings_travis --verbosity=2 --noinput
 - flake8

after_success:
 - coveralls

Migrate smartmin to PostgreSQL 10
Migrate smartmin to PostgreSQL 10
