2013-07-26 02:50:54 +04:00
|
|
|
language: php
|
2016-11-11 23:22:46 +03:00
|
|
|
|
2016-11-24 11:30:41 +03:00
|
|
|
sudo: false
|
|
|
|
|
|
|
|
cache:
|
|
|
|
directories:
|
|
|
|
- $HOME/.composer/cache/files
|
|
|
|
|
2013-07-26 02:50:54 +04:00
|
|
|
php:
|
2016-11-24 11:30:41 +03:00
|
|
|
- 7.1
|
2017-12-01 22:55:29 +03:00
|
|
|
- 7.2
|
2019-01-06 11:01:37 +03:00
|
|
|
- 7.3
|
2020-09-12 14:10:34 +03:00
|
|
|
- 7.4
|
2019-01-06 11:01:37 +03:00
|
|
|
|
|
|
|
branches:
|
|
|
|
except:
|
|
|
|
- /^analysis-.*$/
|
|
|
|
- /^patch-.*$/
|
2016-11-11 23:22:46 +03:00
|
|
|
|
2017-04-08 11:43:04 +03:00
|
|
|
env:
|
2019-01-06 12:37:07 +03:00
|
|
|
- TEST_COMMAND="composer test"
|
2017-04-08 11:43:04 +03:00
|
|
|
|
2016-11-24 11:30:41 +03:00
|
|
|
matrix:
|
|
|
|
fast_finish: true
|
|
|
|
include:
|
2019-01-06 11:01:37 +03:00
|
|
|
- php: 7.1
|
2017-04-08 12:22:20 +03:00
|
|
|
env: COMPOSER_FLAGS="--prefer-stable --prefer-lowest" PREFER_COVERAGE=true
|
2019-01-09 22:17:37 +03:00
|
|
|
- name: Backward compatibility test (Disabled)
|
|
|
|
php: 7.3
|
|
|
|
env: DEPENDENCIES="roave/backward-compatibility-check"
|
|
|
|
script: ./vendor/bin/roave-backward-compatibility-check || true
|
2019-01-10 22:29:58 +03:00
|
|
|
- name: PHPStan
|
|
|
|
php: 7.2
|
2019-01-12 12:09:22 +03:00
|
|
|
env: DEPENDENCIES="phpstan/phpstan"
|
2019-01-17 08:20:08 +03:00
|
|
|
script:
|
|
|
|
- ./vendor/bin/phpstan --version
|
2019-01-17 22:57:22 +03:00
|
|
|
- ./vendor/bin/phpstan analyse
|
2016-11-24 11:30:41 +03:00
|
|
|
|
2019-01-09 22:17:37 +03:00
|
|
|
before_install:
|
2017-04-08 12:22:20 +03:00
|
|
|
- if [[ "$PREFER_COVERAGE" = true ]] && [[ "$TRAVIS_PULL_REQUEST" = false ]]; then TEST_COMMAND="composer test-coverage" COVERAGE=true; fi
|
2019-01-09 22:17:37 +03:00
|
|
|
- if ! [ -z "$DEPENDENCIES" ]; then composer require --no-update ${DEPENDENCIES}; fi;
|
|
|
|
|
|
|
|
install:
|
|
|
|
- composer update ${COMPOSER_FLAGS} --prefer-dist --no-interaction
|
2016-11-11 23:22:46 +03:00
|
|
|
|
2015-04-18 22:20:26 +03:00
|
|
|
script:
|
2019-01-06 11:01:37 +03:00
|
|
|
- composer validate --strict --no-check-lock
|
2016-11-24 11:30:41 +03:00
|
|
|
- echo $TEST_COMMAND
|
|
|
|
- $TEST_COMMAND
|
|
|
|
|
|
|
|
after_success:
|
|
|
|
- if [[ "$COVERAGE" = true ]]; then wget https://scrutinizer-ci.com/ocular.phar; fi
|
|
|
|
- if [[ "$COVERAGE" = true ]]; then php ocular.phar code-coverage:upload --format=php-clover build/coverage.xml; fi
|