-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy path.travis.yml
49 lines (40 loc) · 1.39 KB
/
.travis.yml
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
47
48
49
sudo: false
language: php
cache:
directories:
- $HOME/.composer/cache/files
- $HOME/symfony-bridge/.phpunit
branches:
only:
- master
- /^\d+\.(\d+|x)$/
env:
global:
- SYMFONY_PHPUNIT_DIR="$HOME/symfony-bridge/.phpunit"
- COMPOSER_OPTIONS="--prefer-stable"
matrix:
fast_finish: true
include:
- php: 7.1
env: COMPOSER_OPTIONS="--prefer-lowest --prefer-stable"
- php: 7.2
- php: 7.3
- php: 7.4
# Test against LTS versions
- php: 7.2
env: SYMFONY_LTS="^4"
# Test against dev versions
- php: 7.4
env: xdebug=yes COMPOSER_OPTIONS=""
before_install:
- if [ "$TRAVIS_PHP_VERSION" != "hhvm" ]; then echo memory_limit = -1 >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini; fi
- if [[ "$TRAVIS_PHP_VERSION" != "hhvm" && "$xdebug" != "yes" ]]; then phpenv config-rm xdebug.ini; fi
- if [ "$SYMFONY_LTS" != "" ]; then composer require symfony/lts:${SYMFONY_LTS} --dev --no-update; fi
install:
- composer update $COMPOSER_OPTIONS
- vendor/bin/simple-phpunit install
script:
- if [[ "$xdebug" = "yes" ]]; then vendor/bin/simple-phpunit --coverage-clover=coverage.clover; else vendor/bin/simple-phpunit; fi
after_script:
- if [[ "$xdebug" = "yes" ]]; then wget https://scrutinizer-ci.com/ocular.phar; fi
- if [[ "$xdebug" = "yes" ]]; then php ocular.phar code-coverage:upload --format=php-clover coverage.clover; fi