Skip to content

Commit 1d06964

Browse files
committed
Merge branch 'feature/test-again-php-7.4' of https://github.com/jrfnl/PHP_CodeSniffer
2 parents 817ade6 + 76999f6 commit 1d06964

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

.travis.yml

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,26 +19,35 @@ matrix:
1919
env: CUSTOM_INI=1 PEAR_VALIDATE=1
2020
- php: 7.1
2121
- php: 7.2
22+
env: PHPUNIT_INCOMPAT=1
2223
- php: 7.3
24+
env: PHPUNIT_INCOMPAT=1
25+
- php: "7.4snapshot"
26+
env: PHPSTAN=1 PHPUNIT_INCOMPAT=1
27+
# Nightly is PHP 8.0 since Feb 2019.
2328
- php: nightly
24-
env: PHPSTAN=1
29+
env: PHPUNIT_INCOMPAT=1
2530

2631
allow_failures:
32+
- php: "7.4snapshot"
2733
- php: nightly
2834

2935
before_install:
3036
- export XMLLINT_INDENT=" "
3137
# Speed up build time by disabling Xdebug when its not needed.
3238
- phpenv config-rm xdebug.ini || echo 'No xdebug config.'
39+
# PHPUnit 8.x is not (yet) supported, so prevent issues with Travis images using it.
40+
- if [[ $PHPUNIT_INCOMPAT == "1" && $TRAVIS_PHP_VERSION != "nightly" ]]; then composer install; fi
3341

3442
before_script:
3543
- if [[ $CUSTOM_INI == "1" && ${TRAVIS_PHP_VERSION:0:1} == "5" ]]; then phpenv config-add php5-testingConfig.ini; fi
3644
- if [[ $CUSTOM_INI == "1" ]] && [[ ${TRAVIS_PHP_VERSION:0:1} == "7" || $TRAVIS_PHP_VERSION == "nightly" ]]; then phpenv config-add php7-testingConfig.ini; fi
3745

3846
script:
39-
- composer install
4047
- php bin/phpcs --config-set php_path php
41-
- vendor/bin/phpunit tests/AllTests.php
48+
- if [[ $PHPUNIT_INCOMPAT != "1" ]]; then phpunit tests/AllTests.php; fi
49+
# Don't run the unit tests on nightly (PHP 8.0) as there is no compatible PHPUnit version available yet.
50+
- if [[ $PHPUNIT_INCOMPAT == "1" && $TRAVIS_PHP_VERSION != "nightly" ]]; then vendor/bin/phpunit tests/AllTests.php; fi
4251
- if [[ $CUSTOM_INI != "1" ]]; then php bin/phpcs --no-cache --parallel=1; fi
4352
- if [[ $CUSTOM_INI != "1" && $TRAVIS_PHP_VERSION != "nightly" ]]; then pear package-validate package.xml; fi
4453
- if [[ $PEAR_VALIDATE == "1" ]]; then php scripts/validate-pear-package.php; fi

0 commit comments

Comments
 (0)