sudo: false
language: python
matrix:
  include:
    - python: 2.7
      env: TOX_ENV=py27-WTForms1
    - python: 2.7
      env: TOX_ENV=py27-WTForms2
    - python: 2.7
      env: TOX_ENV=flake8
    - python: 2.7
      env: TOX_ENV=docs-html
    - python: 3.4
      env: TOX_ENV=py34-WTForms1
    - python: 3.4
      env: TOX_ENV=py34-WTForms2
    - python: 3.5
      env: TOX_ENV=py35-WTForms1
    - python: 3.5
      env: TOX_ENV=py35-WTForms2
    - python: 3.6
      env: TOX_ENV=py36-WTForms1
    - python: 3.6
      env: TOX_ENV=py36-WTForms2

addons:
  postgresql: "9.4"
  apt:
    packages:
      - postgresql-9.4-postgis-2.4
      - postgresql-9.4-postgis-2.4-scripts

services:
  - postgresql
  - mongodb
  - docker

before_script:
  - psql -U postgres -c 'CREATE DATABASE flask_admin_test;'
  - psql -U postgres -c 'CREATE EXTENSION postgis;' flask_admin_test
  - psql -U postgres -c 'CREATE EXTENSION hstore;' flask_admin_test
  - docker run --restart always -d -e executable=blob -p 10000:10000 --tmpfs /opt/azurite/folder arafato/azurite:2.6.5

install:
  - pip install tox

script: tox -e $TOX_ENV

after_success:
    - coveralls
