Skip to content

Commit f823775

Browse files
committed
fix build on php 7
1 parent b678bc1 commit f823775

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

.travis.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ branches:
2828
before_script:
2929
# Install deps
3030
- composer update $COMPOSER_FLAGS --dev --prefer-source --no-interaction
31+
- sh -c "if [ '$TRAVIS_PHP_VERSION' = '7' ]; then wget https://phar.phpunit.de/phpunit-5.7.phar; fi"
3132
# Install Varnish
3233
- curl http://repo.varnish-cache.org/debian/GPG-key.txt | sudo apt-key add -
3334
- echo "deb http://repo.varnish-cache.org/ubuntu/ precise varnish-${VARNISH_VERSION}" | sudo tee -a /etc/apt/sources.list
@@ -41,7 +42,8 @@ before_script:
4142
- sh -c "if [ '$TRAVIS_PHP_VERSION' = 'hhvm' ]; then ./tests/ci/install-apache-hhvm.sh; fi"
4243

4344
script:
44-
- phpunit --coverage-clover=coverage.clover
45+
- sh -c "if [ '$TRAVIS_PHP_VERSION' = '7' ]; then php phpunit-5.7.phar --coverage-clover=coverage.clover; fi"
46+
- sh -c "if [ '$TRAVIS_PHP_VERSION' \< '7' ]; then phpunit --coverage-clover=coverage.clover; fi"
4547
- make -C doc SPHINXOPTS='-nW' html
4648
- make -C doc spelling
4749

0 commit comments

Comments
 (0)