forked from sulu/SuluFormBundle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
36 lines (29 loc) · 1.13 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
sudo: false
language: php
cache:
directories:
- "$HOME/.composer/cache/files"
matrix:
include:
- php: 5.5
env:
- COMPOSER_FLAGS="--prefer-dist --no-interaction" # --prefer-lowest TODO FIXME sulu 1.3 issue
- php: 7.0
env:
- COMPOSER_FLAGS="--prefer-dist --no-interaction"
- CODE_COVERAGE=true
- PHPSTAN=true
before_install:
- phpenv config-add Tests/travis.php.ini
- composer self-update
install:
- if [[ $PHPSTAN == 'true' ]]; then travis_retry composer require --dev phpstan/phpstan $COMPOSER_FLAGS ; else travis_retry composer update $COMPOSER_FLAGS ; fi
- composer info -i
- ./Tests/app/console doctrine:database:create
- ./Tests/app/console doctrine:schema:update --force
script:
- ./vendor/bin/phpunit --coverage-clover=coverage.clover
- if [[ $PHPSTAN == 'true' ]]; then ./vendor/bin/phpstan analyse ./ --level 1 -c phpstan.neon ; fi
after_script:
- if [[ $CODE_COVERAGE == 'true' ]]; then wget https://scrutinizer-ci.com/ocular.phar ; fi
- if [[ $CODE_COVERAGE == 'true' ]]; then php ocular.phar code-coverage:upload --format=php-clover coverage.clover ; fi