Chris@0
|
1 language: php
|
Chris@0
|
2 sudo: false
|
Chris@0
|
3 cache:
|
Chris@0
|
4 directories:
|
Chris@0
|
5 - $HOME/.composer/cache/files
|
Chris@12
|
6 - $HOME/symfony-bridge/.phpunit
|
Chris@0
|
7
|
Chris@17
|
8 env:
|
Chris@17
|
9 global:
|
Chris@17
|
10 - PHPUNIT_FLAGS="-v"
|
Chris@17
|
11 - SYMFONY_PHPUNIT_DIR="$HOME/symfony-bridge/.phpunit"
|
Chris@18
|
12 - DEPENDENCIES="nyholm/psr7:^1.1"
|
Chris@17
|
13
|
Chris@0
|
14 matrix:
|
Chris@17
|
15 fast_finish: true
|
Chris@0
|
16 include:
|
Chris@17
|
17 # Minimum supported dependencies with the latest and oldest PHP version
|
Chris@18
|
18 - php: 7.3
|
Chris@17
|
19 env: COMPOSER_FLAGS="--prefer-stable --prefer-lowest" SYMFONY_DEPRECATIONS_HELPER="weak_vendors"
|
Chris@0
|
20 - php: 5.3
|
Chris@12
|
21 dist: 'precise'
|
Chris@17
|
22 env: COMPOSER_FLAGS="--prefer-stable --prefer-lowest" SYMFONY_DEPRECATIONS_HELPER="weak_vendors" DEPENDENCIES=""
|
Chris@17
|
23
|
Chris@17
|
24 # Test the latest stable release
|
Chris@0
|
25 - php: 5.3
|
Chris@12
|
26 dist: 'precise'
|
Chris@18
|
27 env: DEPENDENCIES="symfony/phpunit-bridge:>=3.4,<3.4.22||>=4.0,<4.1.11||>=4.2,<4.2.3"
|
Chris@17
|
28 - php: 5.4
|
Chris@17
|
29 env: DEPENDENCIES="zendframework/zend-diactoros:^1.4.1"
|
Chris@17
|
30 - php: 5.5
|
Chris@17
|
31 env: DEPENDENCIES="zendframework/zend-diactoros:^1.4.1"
|
Chris@0
|
32 - php: 5.6
|
Chris@17
|
33 env: DEPENDENCIES="zendframework/zend-diactoros:^1.4.1"
|
Chris@0
|
34 - php: 7.0
|
Chris@18
|
35 env: DEPENDENCIES="zendframework/zend-diactoros:^1.4.1 http-interop/http-factory-diactoros:^1.0"
|
Chris@17
|
36 - php: 7.1
|
Chris@17
|
37 - php: 7.2
|
Chris@18
|
38 - php: 7.3
|
Chris@17
|
39 env: COVERAGE=true PHPUNIT_FLAGS="-v --coverage-text"
|
Chris@17
|
40
|
Chris@17
|
41 # Test LTS versions. This makes sure we do not use Symfony packages with version greater
|
Chris@17
|
42 # than 2 or 3 respectively.
|
Chris@18
|
43 - php: 7.3
|
Chris@17
|
44 env: DEPENDENCIES="$DEPENDENCIES symfony/lts:^2 symfony/force-lowest:~2.8.0"
|
Chris@18
|
45 - php: 7.3
|
Chris@17
|
46 env: DEPENDENCIES="$DEPENDENCIES symfony/lts:^3 symfony/force-lowest:~3.4.0"
|
Chris@17
|
47
|
Chris@17
|
48 # Latest commit to master
|
Chris@18
|
49 - php: 7.3
|
Chris@17
|
50 env: STABILITY="dev"
|
Chris@17
|
51
|
Chris@0
|
52 allow_failures:
|
Chris@17
|
53 # Dev-master is allowed to fail.
|
Chris@17
|
54 - env: STABILITY="dev"
|
Chris@0
|
55
|
Chris@0
|
56 before_install:
|
Chris@17
|
57 - if [[ $COVERAGE != true ]]; then phpenv config-rm xdebug.ini || true; fi
|
Chris@17
|
58 - if ! [ -z "$STABILITY" ]; then composer config minimum-stability ${STABILITY}; fi;
|
Chris@17
|
59 - if ! [ -v "$DEPENDENCIES" ]; then composer require --no-update ${DEPENDENCIES}; fi;
|
Chris@0
|
60
|
Chris@0
|
61 install:
|
Chris@17
|
62 # To be removed when this issue will be resolved: https://github.com/composer/composer/issues/5355
|
Chris@17
|
63 - if [[ "$COMPOSER_FLAGS" == *"--prefer-lowest"* ]]; then composer update --prefer-dist --no-interaction --prefer-stable --quiet; fi
|
Chris@17
|
64 - composer update ${COMPOSER_FLAGS} --prefer-dist --no-interaction
|
Chris@17
|
65 - ./vendor/bin/simple-phpunit install
|
Chris@0
|
66
|
Chris@0
|
67 script:
|
Chris@17
|
68 - composer validate --strict --no-check-lock
|
Chris@17
|
69 # simple-phpunit is the PHPUnit wrapper provided by the PHPUnit Bridge component and
|
Chris@17
|
70 # it helps with testing legacy code and deprecations (composer require symfony/phpunit-bridge)
|
Chris@17
|
71 - ./vendor/bin/simple-phpunit $PHPUNIT_FLAGS |