Only generate coverage on 7.x
This commit is contained in:
parent
66f253e4a3
commit
212449f391
|
@ -14,9 +14,6 @@ env:
|
|||
# Additional tests against stable PHP (min recommended version is 5.6) and past supported versions of WP.
|
||||
matrix:
|
||||
include:
|
||||
- php: 5.6
|
||||
env: WP_VERSION=latest WP_MULTISITE=1 PHP_LATEST_STABLE=7.1
|
||||
dist: precise
|
||||
- php: 5.3
|
||||
env: WP_VERSION=latest WP_MULTISITE=0 PHP_LATEST_STABLE=7.1
|
||||
dist: precise
|
||||
|
@ -30,8 +27,7 @@ before_script:
|
|||
- bash tests/bin/travis.sh before
|
||||
|
||||
script:
|
||||
- phpunit --version
|
||||
- phpunit -c phpunit.xml --coverage-clover=coverage.clover
|
||||
- bash tests/bin/travis.sh during
|
||||
|
||||
after_script:
|
||||
- bash tests/bin/travis.sh after
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#!/usr/bin/env bash
|
||||
# usage: travis.sh before|after
|
||||
# usage: travis.sh before|during|after
|
||||
|
||||
if [ $1 == 'before' ]; then
|
||||
|
||||
|
@ -17,12 +17,20 @@ if [ $1 == 'before' ]; then
|
|||
|
||||
fi
|
||||
|
||||
if [ $1 == 'after' ]; then
|
||||
if [ $1 == 'during' ]; then
|
||||
|
||||
if [[ ${TRAVIS_PHP_VERSION:0:2} == "7." ]]; then
|
||||
|
||||
bash <(curl -s https://codecov.io/bash)
|
||||
|
||||
phpunit -c phpunit.xml --coverage-clover=coverage.clover
|
||||
else
|
||||
phpunit -c phpunit.xml
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
if [ $1 == 'after' ]; then
|
||||
|
||||
if [[ ${TRAVIS_PHP_VERSION:0:2} == "7." ]]; then
|
||||
bash <(curl -s https://codecov.io/bash)
|
||||
fi
|
||||
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue