Skip to content

Commit 850f211

Browse files
authored
Merge pull request #190 from renatomefi/improve/travis-build
Improving Travis build
2 parents e4e25b4 + c28b543 commit 850f211

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

.travis.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ matrix:
1717
- php: 7.0
1818
env: SYMFONY_VERSION=3.2.*
1919
- php: 7.1
20-
env: SYMFONY_VERSION=3.3.*
20+
env: SYMFONY_VERSION=3.3.* PHPUNIT_FLAGS="-d xdebug.max_nesting_level=1000 --coverage-clover=build/logs/clover.xml"
2121
- php: hhvm
2222
- php: nightly
2323
allow_failures:
@@ -26,18 +26,19 @@ matrix:
2626
cache:
2727
directories:
2828
- $HOME/.composer/cache
29+
- $HOME/.php_cs.cache
2930

3031
before_install:
31-
- if [[ "$TRAVIS_PHP_VERSION" != "5.6" && "$TRAVIS_PHP_VERSION" != "hhvm" ]]; then phpenv config-rm xdebug.ini || true; fi
32+
- if [[ "$TRAVIS_PHP_VERSION" != "7.1" && "$TRAVIS_PHP_VERSION" != "hhvm" ]]; then phpenv config-rm xdebug.ini || true; fi
3233
- composer selfupdate
3334
- if [ "$SYMFONY_VERSION" != "" ]; then composer require "symfony/symfony:${SYMFONY_VERSION}" "symfony/framework-bundle:${SYMFONY_VERSION}" --dev --no-update; fi;
3435

35-
install: composer update --prefer-dist --no-interaction
36+
install: composer update --prefer-source --no-interaction --optimize-autoloader
3637

3738
script:
38-
- if [ "$TRAVIS_PHP_VERSION" == "5.6" ]; then bin/phpunit -d xdebug.max_nesting_level=1000 --debug --coverage-clover=build/logs/clover.xml; else bin/phpunit --debug; fi
39+
- bin/phpunit --debug ${PHPUNIT_FLAGS}
3940
- if [ "$TRAVIS_PHP_VERSION" == "7.0" ]; then bin/php-cs-fixer fix --diff --dry-run -v; fi;
4041

4142
after_script:
42-
- if [ "$TRAVIS_PHP_VERSION" == "5.6" ]; then wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml; fi
43-
- if [ "$TRAVIS_PHP_VERSION" == "5.6" ]; then composer require "satooshi/php-coveralls:^1.0" && travis_retry php bin/coveralls -v; fi
43+
- if [ "$TRAVIS_PHP_VERSION" == "7.1" ]; then wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml; fi
44+
- if [ "$TRAVIS_PHP_VERSION" == "7.1" ]; then composer require "satooshi/php-coveralls:^1.0" && travis_retry php bin/coveralls -v; fi

0 commit comments

Comments
 (0)