.travis.yml 2.18 KB
Newer Older
1 2 3 4 5
language: php

php:
  - 5.3
  - 5.4
6
  - 5.5
7
  - 5.6
8
  - hhvm
9
  - hhvm-nightly
10

11 12
env:
  - DB=mysql
13 14 15
  - DB=pgsql POSTGRESQL_VERSION=9.1
  - DB=pgsql POSTGRESQL_VERSION=9.2
  - DB=pgsql POSTGRESQL_VERSION=9.3
16
  - DB=sqlite
17
  - DB=mysqli
18

till's avatar
till committed
19 20 21 22 23 24
before_install:
  - composer self-update

install:
  - composer update --prefer-source

25 26 27 28 29
before_script:
  - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'DROP DATABASE IF EXISTS doctrine_tests;' -U postgres; fi"
  - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'DROP DATABASE IF EXISTS doctrine_tests_tmp;' -U postgres; fi"
  - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'create database doctrine_tests;' -U postgres; fi"
  - sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'create database doctrine_tests_tmp;' -U postgres; fi"
30
  - sh -c "if [ '$DB' = 'pgsql' ]; then sudo service postgresql stop; sudo service postgresql start $POSTGRESQL_VERSION; fi"
31
  - sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'create database IF NOT EXISTS doctrine_tests_tmp;create database IF NOT EXISTS doctrine_tests;'; fi"
32
  - sh -c "if [ '$DB' = 'mysqli' ]; then mysql -e 'create database IF NOT EXISTS doctrine_tests_tmp;create database IF NOT EXISTS doctrine_tests;'; fi"
33

34
script: ./vendor/bin/phpunit --configuration tests/travis/$DB.travis.xml
35

36 37
matrix:
  allow_failures:
38 39 40 41 42 43 44 45
      - php: hhvm
        env: DB=pgsql POSTGRESQL_VERSION=9.1
      - php: hhvm
        env: DB=pgsql POSTGRESQL_VERSION=9.2
      - php: hhvm
        env: DB=pgsql POSTGRESQL_VERSION=9.3
      - php: hhvm
        env: DB=sqlite
46 47
      - php: hhvm
        env: DB=mysql
48
      - php: hhvm-nightly
49 50
  exclude:
      - php: hhvm
51 52 53 54 55
        env: DB=pgsql POSTGRESQL_VERSION=9.1 # driver currently unsupported by HHVM
      - php: hhvm
        env: DB=pgsql POSTGRESQL_VERSION=9.2 # driver currently unsupported by HHVM
      - php: hhvm
        env: DB=pgsql POSTGRESQL_VERSION=9.3 # driver currently unsupported by HHVM
56 57 58 59 60 61
      - php: hhvm-nightly
        env: DB=pgsql POSTGRESQL_VERSION=9.1 # driver currently unsupported by HHVM
      - php: hhvm-nightly
        env: DB=pgsql POSTGRESQL_VERSION=9.2 # driver currently unsupported by HHVM
      - php: hhvm-nightly
        env: DB=pgsql POSTGRESQL_VERSION=9.3 # driver currently unsupported by HHVM