Move code coverage to Scrutinizer
This commit is contained in:
parent
383c7eb889
commit
4251bd5614
|
@ -1,3 +0,0 @@
|
||||||
src_dir: .
|
|
||||||
coverage_clover: ./tmp/clover.xml
|
|
||||||
json_path: ./tmp/coveralls-upload.json
|
|
|
@ -30,5 +30,24 @@ checks:
|
||||||
|
|
||||||
tools:
|
tools:
|
||||||
sensiolabs_security_checker: true
|
sensiolabs_security_checker: true
|
||||||
external_code_coverage:
|
|
||||||
timeout: 600 # Wait 10 minutes for Travis send coverage file.
|
build:
|
||||||
|
environment:
|
||||||
|
php: '7.1'
|
||||||
|
mysql: true
|
||||||
|
apache2:
|
||||||
|
modules: ['rewrite']
|
||||||
|
variables:
|
||||||
|
WP_VERSION: 'latest'
|
||||||
|
dependencies:
|
||||||
|
before:
|
||||||
|
- bash tests/bin/install.sh woocommerce_test root '' localhost $WP_VERSION
|
||||||
|
- curl -sS https://getcomposer.org/installer | php
|
||||||
|
- php composer.phar install
|
||||||
|
tests:
|
||||||
|
override:
|
||||||
|
-
|
||||||
|
command: 'vendor/bin/phpunit --coverage-clover=results'
|
||||||
|
coverage:
|
||||||
|
file: 'results'
|
||||||
|
format: 'clover'
|
||||||
|
|
|
@ -29,7 +29,7 @@ before_script:
|
||||||
- bash tests/bin/travis.sh before
|
- bash tests/bin/travis.sh before
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- bash tests/bin/phpunit.sh
|
- phpunit -c phpunit.xml.dist
|
||||||
|
|
||||||
after_script:
|
after_script:
|
||||||
- bash tests/bin/travis.sh after
|
- bash tests/bin/travis.sh after
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
if [[ ${TRAVIS_BRANCH} == 'master' ]] && [[ ${TRAVIS_EVENT_TYPE} != 'pull_request' ]] && [[ ${TRAVIS_PHP_VERSION} == ${PHP_LATEST_STABLE} ]]; then
|
|
||||||
phpunit -c phpunit.xml.dist --coverage-clover ./tmp/clover.xml
|
|
||||||
else
|
|
||||||
phpunit -c phpunit.xml.dist
|
|
||||||
fi
|
|
|
@ -15,13 +15,4 @@ if [ $1 == 'before' ]; then
|
||||||
composer global require "phpunit/phpunit=6.2.*"
|
composer global require "phpunit/phpunit=6.2.*"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
elif [ $1 == 'after' ]; then
|
|
||||||
|
|
||||||
# Only run on master, not pull requests, latest stable PHP box (defined in .travis.yml).
|
|
||||||
if [[ ${TRAVIS_BRANCH} == 'master' ]] && [[ ${TRAVIS_EVENT_TYPE} != 'pull_request' ]] && [[ ${TRAVIS_PHP_VERSION} == ${PHP_LATEST_STABLE} ]]; then
|
|
||||||
wget https://scrutinizer-ci.com/ocular.phar
|
|
||||||
chmod +x ocular.phar
|
|
||||||
php ocular.phar code-coverage:upload --format=php-clover ./tmp/clover.xml
|
|
||||||
fi
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue