Integrate with Codecov

parent 18a053ad
...@@ -20,18 +20,22 @@ environment: ...@@ -20,18 +20,22 @@ environment:
- db: mssql - db: mssql
driver: sqlsrv driver: sqlsrv
db_version: sql2008r2sp2 db_version: sql2008r2sp2
coverage: yes
php: 7.3 php: 7.3
- db: mssql - db: mssql
driver: sqlsrv driver: sqlsrv
db_version: sql2012sp1 db_version: sql2012sp1
coverage: yes
php: 7.3 php: 7.3
- db: mssql - db: mssql
driver: sqlsrv driver: sqlsrv
db_version: sql2017 db_version: sql2017
coverage: no
php: 7.3 php: 7.3
- db: mssql - db: mssql
driver: pdo_sqlsrv driver: pdo_sqlsrv
db_version: sql2017 db_version: sql2017
coverage: yes
php: 7.3 php: 7.3
init: init:
...@@ -123,8 +127,16 @@ test_script: ...@@ -123,8 +127,16 @@ test_script:
$env:phpunit_config = "tests\appveyor\$($env:db).$($env:driver).appveyor.xml" $env:phpunit_config = "tests\appveyor\$($env:db).$($env:driver).appveyor.xml"
} }
if ($env:coverage -eq "yes") {
vendor\bin\phpunit -c $($env:phpunit_config) --coverage-clover clover.xml
} else {
vendor\bin\phpunit -c $($env:phpunit_config) vendor\bin\phpunit -c $($env:phpunit_config)
}
if ($LastExitCode -ne 0) { if ($LastExitCode -ne 0) {
$host.SetShouldExit($LastExitCode) $host.SetShouldExit($LastExitCode)
} }
after_test:
- appveyor DownloadFile https://codecov.io/bash -FileName codecov.sh
- bash codecov.sh -f clover.xml
...@@ -39,6 +39,12 @@ after_script: ...@@ -39,6 +39,12 @@ after_script:
travis_retry coveralls -v travis_retry coveralls -v
fi fi
after_success:
- |
if [ "x$COVERAGE" == "xyes" ]; then
bash <(curl -s https://codecov.io/bash)
fi
jobs: jobs:
include: include:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment