File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed
Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change 2121 - 7.1
2222 - 7.2
2323 - 7.3
24- - nightly
24+ - " 7.4snapshot "
2525
2626env :
2727 # `master` is now 3.x.
@@ -42,7 +42,7 @@ matrix:
4242
4343 allow_failures :
4444 # Allow failures for unstable builds.
45- - php : nightly
45+ - php : " 7.4snapshot "
4646
4747before_install :
4848 # Speed up build time by disabling Xdebug.
@@ -60,12 +60,20 @@ before_install:
6060 # The above require already does the install.
6161 $(pwd)/vendor/bin/phpcs --config-set installed_paths $(pwd)
6262 fi
63+ # Download PHPUnit 7.x for builds on PHP >= 7.2 as the PHPCS
64+ # test suite is currently not compatible with PHPUnit 8.x.
65+ - if [[ ${TRAVIS_PHP_VERSION:0:3} > "7.1" ]]; then wget -P $PHPUNIT_DIR https://phar.phpunit.de/phpunit-7.phar && chmod +x $PHPUNIT_DIR/phpunit-7.phar; fi
6366
6467script :
6568 # Lint the PHP files against parse errors.
6669 - if [[ "$LINT" == "1" ]]; then if find . -path ./vendor -prune -o -path ./bin -prune -o -name "*.php" -exec php -l {} \; | grep "^[Parse error|Fatal error]"; then exit 1; fi; fi
6770 # Run the unit tests.
68- - phpunit --filter WordPress --bootstrap="$(pwd)/vendor/squizlabs/php_codesniffer/tests/bootstrap.php" $(pwd)/vendor/squizlabs/php_codesniffer/tests/AllTests.php
71+ - |
72+ if [[ ${TRAVIS_PHP_VERSION:0:3} > "7.1" ]]; then
73+ php $PHPUNIT_DIR/phpunit-7.phar --filter WordPress --bootstrap="$(pwd)/vendor/squizlabs/php_codesniffer/tests/bootstrap.php" $(pwd)/vendor/squizlabs/php_codesniffer/tests/AllTests.php
74+ else
75+ phpunit --filter WordPress --bootstrap="$(pwd)/vendor/squizlabs/php_codesniffer/tests/bootstrap.php" $(pwd)/vendor/squizlabs/php_codesniffer/tests/AllTests.php
76+ fi
6977 # Test for fixer conflicts by running the auto-fixers of the complete WPCS over the test case files.
7078 # This is not an exhaustive test, but should give an early indication for typical fixer conflicts.
7179 # For the first run, the exit code will be 1 (= all fixable errors fixed).
You can’t perform that action at this time.
0 commit comments