Skip to content

Commit

Permalink
Merge pull request #4053 from greg0ire/make-coverage-unconditional-on…
Browse files Browse the repository at this point in the history
…-travis

Report coverage unconditionally on Travis
  • Loading branch information
greg0ire authored Jun 6, 2020
2 parents 87aad2f + 6c83f5a commit 0ad4c16
Showing 1 changed file with 26 additions and 37 deletions.
63 changes: 26 additions & 37 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@ cache:

before_install:
- phpenv config-rm xdebug.ini || true
- |
if [ "x$COVERAGE" == "xyes" ]; then
pecl install pcov-1.0.0
fi
- pecl install pcov

before_script:
- |
Expand All @@ -24,25 +21,17 @@ install:
- travis_retry composer -n install --prefer-dist

script:
- |
if [ "x$COVERAGE" == "xyes" ]; then
./vendor/bin/phpunit --configuration tests/travis/$DB.travis.xml --coverage-clover clover.xml
else
./vendor/bin/phpunit --configuration tests/travis/$DB.travis.xml
fi
- ./vendor/bin/phpunit --configuration tests/travis/$DB.travis.xml --coverage-clover clover.xml

after_success:
- |
if [ "x$COVERAGE" == "xyes" ]; then
bash <(curl -s https://codecov.io/bash)
fi
- bash <(curl -s https://codecov.io/bash)

jobs:
include:

- stage: Smoke Testing
php: 7.3
env: DB=sqlite COVERAGE=yes
env: DB=sqlite

- stage: Test
php: 7.2
Expand Down Expand Up @@ -83,104 +72,104 @@ jobs:
- bash ./tests/travis/install-mssql.sh
- stage: Test
php: 7.3
env: DB=mysql.docker IMAGE=mysql:5.7 COVERAGE=yes
env: DB=mysql.docker IMAGE=mysql:5.7
- stage: Test
php: 7.3
env: DB=mysql.docker IMAGE=mysql:8.0 COVERAGE=yes
env: DB=mysql.docker IMAGE=mysql:8.0
- stage: Test
php: 7.3
env: DB=mysqli.docker IMAGE=mysql:5.7 COVERAGE=yes
env: DB=mysqli.docker IMAGE=mysql:5.7
- stage: Test
php: 7.3
env: DB=mysqli.docker IMAGE=mysql:8.0 COVERAGE=yes
env: DB=mysqli.docker IMAGE=mysql:8.0
- stage: Test
php: 7.3
env: DB=mariadb.docker IMAGE=mariadb:10.0 COVERAGE=yes
env: DB=mariadb.docker IMAGE=mariadb:10.0
- stage: Test
php: 7.3
env: DB=mariadb.docker IMAGE=mariadb:10.1 COVERAGE=yes
env: DB=mariadb.docker IMAGE=mariadb:10.1
- stage: Test
php: 7.3
env: DB=mariadb.docker IMAGE=mariadb:10.2 COVERAGE=yes
env: DB=mariadb.docker IMAGE=mariadb:10.2
- stage: Test
php: 7.3
env: DB=mariadb.docker IMAGE=mariadb:10.3 COVERAGE=yes
env: DB=mariadb.docker IMAGE=mariadb:10.3
- stage: Test
php: 7.3
env: DB=mariadb.mysqli.docker IMAGE=mariadb:10.0 COVERAGE=yes
env: DB=mariadb.mysqli.docker IMAGE=mariadb:10.0
- stage: Test
php: 7.3
env: DB=mariadb.mysqli.docker IMAGE=mariadb:10.1 COVERAGE=yes
env: DB=mariadb.mysqli.docker IMAGE=mariadb:10.1
- stage: Test
php: 7.3
env: DB=mariadb.mysqli.docker IMAGE=mariadb:10.2 COVERAGE=yes
env: DB=mariadb.mysqli.docker IMAGE=mariadb:10.2
- stage: Test
php: 7.3
env: DB=mariadb.mysqli.docker IMAGE=mariadb:10.3 COVERAGE=yes
env: DB=mariadb.mysqli.docker IMAGE=mariadb:10.3
- stage: Test
dist: trusty
php: 7.3
env: DB=pgsql POSTGRESQL_VERSION=9.2 COVERAGE=yes
env: DB=pgsql POSTGRESQL_VERSION=9.2
services:
- postgresql
addons:
postgresql: "9.2"
- stage: Test
dist: trusty
php: 7.3
env: DB=pgsql POSTGRESQL_VERSION=9.3 COVERAGE=yes
env: DB=pgsql POSTGRESQL_VERSION=9.3
services:
- postgresql
addons:
postgresql: "9.3"
- stage: Test
php: 7.3
env: DB=pgsql POSTGRESQL_VERSION=9.4 COVERAGE=yes
env: DB=pgsql POSTGRESQL_VERSION=9.4
addons:
postgresql: "9.4"
- stage: Test
php: 7.3
env: DB=pgsql POSTGRESQL_VERSION=9.5 COVERAGE=yes
env: DB=pgsql POSTGRESQL_VERSION=9.5
addons:
postgresql: "9.5"
- stage: Test
php: 7.3
env: DB=pgsql POSTGRESQL_VERSION=9.6 COVERAGE=yes
env: DB=pgsql POSTGRESQL_VERSION=9.6
addons:
postgresql: "9.6"
- stage: Test
php: 7.3
env: DB=pgsql POSTGRESQL_VERSION=10.0 COVERAGE=yes
env: DB=pgsql POSTGRESQL_VERSION=10.0
sudo: required
addons:
postgresql: "10"
before_script:
- bash ./tests/travis/install-postgres-10.sh
- stage: Test
php: 7.3
env: DB=pgsql POSTGRESQL_VERSION=11.0 COVERAGE=yes
env: DB=pgsql POSTGRESQL_VERSION=11.0
sudo: required
before_script:
- bash ./tests/travis/install-postgres-11.sh
- stage: Test
php: 7.3
env: DB=sqlsrv COVERAGE=yes
env: DB=sqlsrv
sudo: required
before_script:
- bash ./tests/travis/install-sqlsrv-dependencies.sh
- bash ./tests/travis/install-mssql-sqlsrv.sh
- bash ./tests/travis/install-mssql.sh
- stage: Test
php: 7.3
env: DB=pdo_sqlsrv COVERAGE=yes
env: DB=pdo_sqlsrv
sudo: required
before_script:
- bash ./tests/travis/install-sqlsrv-dependencies.sh
- bash ./tests/travis/install-mssql-pdo_sqlsrv.sh
- bash ./tests/travis/install-mssql.sh
- stage: Test
php: 7.3
env: DB=ibm_db2 COVERAGE=yes
env: DB=ibm_db2
sudo: required
before_script:
- bash ./tests/travis/install-db2.sh
Expand Down

0 comments on commit 0ad4c16

Please sign in to comment.