Feature/integrate codacy (#9)

* REFACTOR: Move scripts to Makefile

* FEATURE: Add codacy
This commit is contained in:
Daniel Siepmann 2016-12-12 22:47:45 +01:00 committed by GitHub
parent dc8e04b449
commit e1e867befd
2 changed files with 14 additions and 3 deletions

View file

@ -46,9 +46,7 @@ install: make install
script: make Tests
after_script:
- wget https://scrutinizer-ci.com/ocular.phar
- php ocular.phar code-coverage:upload --format=php-clover .Build/report/unit/clover/coverage
- php ocular.phar code-coverage:upload --format=php-clover .Build/report/functional/clover/coverage
- make uploadCodeCoverage
- make clean
cache:

View file

@ -31,5 +31,18 @@ functionalTests:
.PHONY: Tests
Tests: unitTests functionalTests
uploadCodeCoverage: uploadCodeCoverageToScrutinizer uploadCodeCoverageToCodacy
uploadCodeCoverageToScrutinizer:
wget https://scrutinizer-ci.com/ocular.phar && \
php ocular.phar code-coverage:upload --format=php-clover .Build/report/unit/clover/coverage && \
php ocular.phar code-coverage:upload --format=php-clover .Build/report/functional/clover/coverage
uploadCodeCoverageToCodacy:
composer require -vv --dev codacy/coverage && \
git checkout composer.json && \
php .Build/bin/codacycoverage clover .Build/report/unit/clover/coverage && \
php .Build/bin/codacycoverage clover .Build/report/functional/clover/coverage
clean:
rm -rf .Build composer.lock