@@ -48,7 +48,7 @@ build: bin/php-scoper src vendor vendor-bin/box/vendor scoper.inc.php box.json
4848# #---------------------------------------------------------------------------
4949
5050test : # # Run all the tests
51- test : tu e2e
51+ test : tc e2e
5252
5353tu : # # Run PHPUnit tests
5454tu : vendor/bin/phpunit
@@ -57,7 +57,9 @@ tu: vendor/bin/phpunit
5757tc : # # Run PHPUnit tests with test coverage
5858tc : vendor/bin/phpunit vendor-bin/covers-validator/vendor
5959 $(COVERS_VALIDATOR )
60- phpdbg -qrr -d zend.enable_gc=0 $(PHPUNIT ) --coverage-html=dist/coverage --coverage-text
60+ phpdbg -qrr -d zend.enable_gc=0 $(PHPUNIT ) --coverage-html=dist/coverage --coverage-text --coverage-clover=clover.xml --coverage-xml=dist/infection-coverage/coverage-xml --log-junit=dist/infection-coverage/phpunit.junit.xml
61+
62+ php -d zend.enable_gc=0 $(PHPUNIT)
6163
6264tm : # # Run Infection (Mutation Testing)
6365tm : vendor/bin/phpunit
@@ -152,18 +154,13 @@ e2e_019: bin/php-scoper.phar fixtures/set019-symfony-console/vendor
152154 diff fixtures/set019-symfony-console/expected-output build/set019-symfony-console/output
153155
154156e2e_020 : # # Run end-to-end tests for the fixture set 020: Infection
155- e2e_020 : bin/php-scoper.phar fixtures/set020-infection/vendor
157+ e2e_020 : bin/php-scoper.phar fixtures/set020-infection/vendor clover.xml
156158 php -d zend.enable_gc=0 $(PHPSCOPER ) add-prefix --working-dir=fixtures/set020-infection --output-dir=../../build/set020-infection --force --no-interaction --stop-on-failure
157159 composer --working-dir=build/set020-infection dump-autoload
158160
159- # Create coverage reports to be able to run Infection without running the tests
160- php -d zend.enable_gc=0 $(PHPUNIT) --coverage-clover=clover.xml --coverage-xml=dist/infection-coverage/coverage-xml --log-junit=dist/infection-coverage/phpunit.junit.xml
161-
162161 php fixtures/set020-infection/vendor/infection/infection/bin/infection --coverage=dist/infection-coverage > build/set020-infection/expected-output
163162 php build/set020-infection/vendor/infection/infection/bin/infection --coverage=dist/infection-coverage > build/set020-infection/output
164163
165- rm clover.xml
166-
167164 diff build/set020-infection/expected-output build/set020-infection/output
168165
169166tb : # # Run Blackfire profiling
@@ -257,3 +254,6 @@ bin/php-scoper.phar: bin/php-scoper src vendor vendor-bin/box/vendor scoper.inc.
257254
258255box.json :
259256 cat box.json.dist | sed -E ' s/\"key\": \".+\",//g' | sed -E ' s/\"algorithm\": \".+\",//g' > box.json
257+
258+ clover.xml : src
259+ $(MAKE ) tc
0 commit comments