/
.travis.yml
54 lines (46 loc) · 1.48 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
50
51
52
53
54
language: php
cache:
directories:
- $HOME/.composer/cache/files
services:
- mysql
php:
- 7.2
- 7.3
env:
- SYMFONY_REQUIRE="3.4.*"
- SYMFONY_REQUIRE="4.3.*"
- PHPUNIT_VERSION="8.*"
matrix:
include:
- php: 7.3
env:
- TEST_COVERAGE=true
- php: 7.3
env:
- PHPUNIT_VERSION="7.*"
- SYMFONY_REQUIRE="3.4.*"
- php: 7.3
env:
- STABILITY=dev
- SYMFONY_REQUIRE="5.0.*"
before_install:
- phpenv config-rm xdebug.ini || echo "xDebug not disabled"
- composer global require --no-progress --no-scripts --no-plugins symfony/flex
install:
- rm -rf composer.lock vendor/*
- if ! [ -z "$STABILITY" ]; then composer config minimum-stability ${STABILITY}; fi;
- cat composer.json
- composer require phpunit/phpunit:${PHPUNIT_VERSION:-"8.*"} --update-with-all-dependencies
script:
- cp tests/Functional/parameters.yml.dist tests/Functional/parameters.yml
- rm -rf tests/Functional/cache
- make phpstan php_cs_fixer_check
- |
if [[ ${TEST_COVERAGE} ]]; then phpdbg -qrr vendor/bin/phpunit -c tests/ --coverage-clover ./build/logs/clover.xml;
elif [[ ${PHPUNIT_VERSION} == "7.*" ]]; then vendor/bin/phpunit -c tests/phpunit7.xml tests/;
else vendor/bin/phpunit -c tests/ tests/;
fi
after_success:
- if [[ ${TEST_COVERAGE} ]]; then wget https://scrutinizer-ci.com/ocular.phar; fi
- if [[ ${TEST_COVERAGE} ]]; then php ocular.phar code-coverage:upload --format=php-clover ./build/logs/clover.xml; fi