From f396ee7242a1bd7358db6edae2a2fa13a18810e0 Mon Sep 17 00:00:00 2001 From: Garion Herman Date: Mon, 18 Nov 2019 14:00:27 +1300 Subject: [PATCH 1/2] Update and expand Travis config --- .travis.yml | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 7a70cdc..8c6fa68 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,5 +1,11 @@ language: php +dist: xenial + +services: + - mysql + - postgresql + env: global: - COMPOSER_ROOT_VERSION="2.x-dev" @@ -7,19 +13,23 @@ env: matrix: include: - php: 5.6 - env: DB=MYSQL PHPCS_TEST=1 PHPUNIT_TEST=1 + env: DB=MYSQL PHPCS_TEST=1 PHPUNIT_TEST=1 RECIPE_VERSION="^1 --prefer-lowest" - php: 7.0 - env: DB=PGSQL PHPUNIT_TEST=1 + env: DB=PGSQL PHPUNIT_TEST=1 RECIPE_VERSION="^1" - php: 7.1 - env: DB=MYSQL PHPUNIT_COVERAGE_TEST=1 + env: DB=MYSQL PHPUNIT_COVERAGE_TEST=1 RECIPE_VERSION="^4 --prefer-lowest" + - php: 7.2 + env: DB=MYSQL PHPUNIT_TEST=1 PHPCS_TEST=1 RECIPE_VERSION="^4" + - php: 7.3 + env: DB=MYSQL PHPUNIT_COVERAGE_TEST=1 RECIPE_VERSION="4.x-dev" before_script: - phpenv rehash - phpenv config-rm xdebug.ini - composer install --prefer-dist - - composer require --prefer-dist --no-update silverstripe/recipe-cms:1.0.x-dev - - if [[ $DB == PGSQL ]]; then composer require --prefer-dist --no-update silverstripe/postgresql:2.0.x-dev; fi + - composer require --prefer-dist --no-update silverstripe/recipe-cms:$RECIPE_VERSION + - if [[ $DB == PGSQL ]]; then composer require --prefer-dist --no-update silverstripe/postgresql:^2; fi - composer update script: From 42af10671e9f356ccd03ba28883c21c60876520a Mon Sep 17 00:00:00 2001 From: Garion Herman Date: Mon, 18 Nov 2019 14:20:09 +1300 Subject: [PATCH 2/2] FIX Fetch source so that PHPCS config is available --- .travis.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 8c6fa68..2f54994 100644 --- a/.travis.yml +++ b/.travis.yml @@ -13,7 +13,7 @@ env: matrix: include: - php: 5.6 - env: DB=MYSQL PHPCS_TEST=1 PHPUNIT_TEST=1 RECIPE_VERSION="^1 --prefer-lowest" + env: DB=MYSQL PHPUNIT_TEST=1 RECIPE_VERSION="^1 --prefer-lowest" - php: 7.0 env: DB=PGSQL PHPUNIT_TEST=1 RECIPE_VERSION="^1" - php: 7.1 @@ -27,10 +27,10 @@ before_script: - phpenv rehash - phpenv config-rm xdebug.ini - - composer install --prefer-dist - - composer require --prefer-dist --no-update silverstripe/recipe-cms:$RECIPE_VERSION - - if [[ $DB == PGSQL ]]; then composer require --prefer-dist --no-update silverstripe/postgresql:^2; fi - - composer update + - composer validate + - composer require --no-update silverstripe/recipe-cms:$RECIPE_VERSION + - if [[ $DB == PGSQL ]]; then composer require --no-update silverstripe/postgresql:^2; fi + - composer install --prefer-source --no-interaction --no-progress --no-suggest --optimize-autoloader --verbose --profile script: - if [[ $PHPUNIT_TEST ]]; then vendor/bin/phpunit; fi