2017-10-10 15:23:17 +02:00
|
|
|
language: php
|
2015-07-20 17:10:08 +02:00
|
|
|
|
2017-11-21 05:35:20 +01:00
|
|
|
dist: trusty
|
2014-02-18 05:59:32 +01:00
|
|
|
|
2017-11-21 05:35:20 +01:00
|
|
|
cache:
|
|
|
|
directories:
|
|
|
|
- $HOME/.composer/cache/files
|
2016-03-23 12:20:55 +01:00
|
|
|
|
2014-02-18 05:59:32 +01:00
|
|
|
php:
|
2016-03-23 12:20:55 +01:00
|
|
|
- 5.6
|
|
|
|
- 7.0
|
2017-10-10 15:23:17 +02:00
|
|
|
- 7.1
|
2014-02-18 05:59:32 +01:00
|
|
|
|
|
|
|
env:
|
2017-11-21 05:35:20 +01:00
|
|
|
global:
|
|
|
|
- DB=SQLITE
|
|
|
|
- PDO=1
|
2016-03-23 12:20:55 +01:00
|
|
|
|
|
|
|
matrix:
|
2017-10-10 15:23:17 +02:00
|
|
|
fast_finish: true
|
2016-03-23 12:20:55 +01:00
|
|
|
include:
|
|
|
|
- php: 5.6
|
2017-11-21 05:35:20 +01:00
|
|
|
env: PDO=0 PHPCS_TEST=1
|
2014-02-18 05:59:32 +01:00
|
|
|
|
|
|
|
before_script:
|
2017-10-10 15:23:17 +02:00
|
|
|
# Init PHP
|
|
|
|
- phpenv rehash
|
|
|
|
- phpenv config-rm xdebug.ini
|
2017-11-21 05:35:20 +01:00
|
|
|
- export PATH=~/.composer/vendor/bin:$PATH
|
2017-10-10 15:23:17 +02:00
|
|
|
- echo 'memory_limit = 2048M' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
|
|
|
|
|
|
|
|
# Install composer dependencies
|
|
|
|
- composer validate
|
2017-11-21 05:35:20 +01:00
|
|
|
- composer require --no-update silverstripe/recipe-cms:1.0.x-dev
|
2017-10-10 15:23:17 +02:00
|
|
|
- composer install --prefer-dist --no-interaction --no-progress --no-suggest --optimize-autoloader --verbose --profile
|
2017-11-21 05:35:20 +01:00
|
|
|
- if [[ $PHPCS_TEST ]]; then composer global require squizlabs/php_codesniffer:^3 --prefer-dist --no-interaction --no-progress --no-suggest -o; fi
|
2014-02-18 05:59:32 +01:00
|
|
|
|
2016-03-23 12:20:55 +01:00
|
|
|
script:
|
2017-10-10 15:23:17 +02:00
|
|
|
- vendor/bin/phpunit vendor/silverstripe/framework/tests
|
2017-11-21 05:35:20 +01:00
|
|
|
- if [[ $PHPCS_TEST ]]; then composer run-script lint; fi
|