From c41929546650a67d141a4f6226a8a7b82940712b Mon Sep 17 00:00:00 2001 From: Aidan Woods Date: Wed, 5 Dec 2018 09:19:00 +0100 Subject: [PATCH] Remove unsupported dependencies when running unit tests (PHP < 7 compat) --- .travis.yml | 7 +++++-- composer.json | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index fb1a5c8..687ce7b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -25,10 +25,11 @@ matrix: - php: nightly install: + # remove everything to prevent composer trying to resolve these, see: https://github.com/composer/composer/issues/6011 + - composer remove friendsofphp/php-cs-fixer --dev --no-update --no-interaction - composer install --prefer-dist --no-interaction --no-progress -script: - - composer test-units +script: composer test-units cache: directories: @@ -38,12 +39,14 @@ jobs: include: - stage: Code Style and Static Analysis php: 7.2 + install: composer install --prefer-dist --no-interaction --no-progress script: - '[ -z "$TRAVIS_TAG" ] || [ "$TRAVIS_TAG" == "$(php -r "require(\"vendor/autoload.php\"); echo Erusev\Parsedown\Parsedown::version;")" ]' - composer test-formatting - stage: Test CommonMark (weak) php: 7.2 + install: composer install --prefer-dist --no-interaction --no-progress script: - composer test-commonmark-weak || true allow_failures: diff --git a/composer.json b/composer.json index 392b772..2f1b735 100644 --- a/composer.json +++ b/composer.json @@ -13,11 +13,11 @@ } ], "require": { - "php": ">=5.3.0", + "php": ">=5.5.0", "ext-mbstring": "*" }, "require-dev": { - "phpunit/phpunit": "^7.4", + "phpunit/phpunit": "^7.4|^6.5.13|^5.7.27|^4.8.36", "friendsofphp/php-cs-fixer": "^2.13" }, "autoload": {