diff --git a/.travis.yml b/.travis.yml index 119615698..5cf55705d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -24,10 +24,8 @@ cache: env: global: - PATH="$HOME/.local/bin:$PATH" - - SYMFONY_DEPRECATIONS_HELPER=max[self]=0 - TARGET=test - UPSTREAM_URL=https://github.com/sonata-project/SonataUserBundle.git - - PHPUNIT_VERSION=8 matrix: fast_finish: true @@ -70,6 +68,7 @@ install: - if [ -x .travis/install_${TARGET}.sh ]; then .travis/install_${TARGET}.sh; fi; before_script: + - phpenv config-rm xdebug.ini - if [ -x .travis/before_script_${TARGET}.sh ]; then .travis/before_script_${TARGET}.sh; fi; script: make $TARGET diff --git a/.travis/install_test.sh b/.travis/install_test.sh index c0794fd16..c02c107cc 100755 --- a/.travis/install_test.sh +++ b/.travis/install_test.sh @@ -3,11 +3,10 @@ set -ev mkdir --parents "${HOME}/bin" -wget "https://phar.phpunit.de/phpunit-${PHPUNIT_VERSION}.phar" --output-document="${HOME}/bin/phpunit" -chmod u+x "${HOME}/bin/phpunit" - # Coveralls client install wget https://github.com/satooshi/php-coveralls/releases/download/v1.0.1/coveralls.phar --output-document="${HOME}/bin/coveralls" chmod u+x "${HOME}/bin/coveralls" +pecl install pcov + composer update --prefer-dist --no-interaction --prefer-stable ${COMPOSER_FLAGS} diff --git a/Makefile b/Makefile index 3e7fd990e..2e849e04c 100644 --- a/Makefile +++ b/Makefile @@ -54,18 +54,11 @@ cs-fix-xml: build: mkdir $@ -HAS_XDEBUG=$(shell php --modules|grep --quiet xdebug;echo $$?) - -build/xdebug-filter.php: phpunit.xml.dist build -ifeq ($(HAS_XDEBUG), 0) - phpunit --dump-xdebug-filter $@ -endif - -test: build/xdebug-filter.php -ifeq ($(HAS_XDEBUG), 0) - phpunit --prepend build/xdebug-filter.php -c phpunit.xml.dist --coverage-clover build/logs/clover.xml +test: +ifeq ($(shell php --modules|grep --quiet pcov;echo $$?), 0) + vendor/bin/simple-phpunit -c phpunit.xml.dist --coverage-clover build/logs/clover.xml else - phpunit -c phpunit.xml.dist + vendor/bin/simple-phpunit -c phpunit.xml.dist endif .PHONY: test diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 7e5cdfda7..80ed99214 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -22,10 +22,6 @@ It's auto-generated by sonata-project/dev-kit package. - - - - ./src/ @@ -33,7 +29,10 @@ It's auto-generated by sonata-project/dev-kit package. - + + + +