Remove unsupported dependencies when running unit tests (PHP < 7 compat)

This commit is contained in:
Aidan Woods 2018-12-05 09:19:00 +01:00
parent 23b07fa185
commit c419295466
No known key found for this signature in database
GPG Key ID: 9A6A8EFAA512BBB9
2 changed files with 7 additions and 4 deletions

View File

@ -25,10 +25,11 @@ matrix:
- php: nightly - php: nightly
install: 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 - composer install --prefer-dist --no-interaction --no-progress
script: script: composer test-units
- composer test-units
cache: cache:
directories: directories:
@ -38,12 +39,14 @@ jobs:
include: include:
- stage: Code Style and Static Analysis - stage: Code Style and Static Analysis
php: 7.2 php: 7.2
install: composer install --prefer-dist --no-interaction --no-progress
script: script:
- '[ -z "$TRAVIS_TAG" ] || [ "$TRAVIS_TAG" == "$(php -r "require(\"vendor/autoload.php\"); echo Erusev\Parsedown\Parsedown::version;")" ]' - '[ -z "$TRAVIS_TAG" ] || [ "$TRAVIS_TAG" == "$(php -r "require(\"vendor/autoload.php\"); echo Erusev\Parsedown\Parsedown::version;")" ]'
- composer test-formatting - composer test-formatting
- stage: Test CommonMark (weak) - stage: Test CommonMark (weak)
php: 7.2 php: 7.2
install: composer install --prefer-dist --no-interaction --no-progress
script: script:
- composer test-commonmark-weak || true - composer test-commonmark-weak || true
allow_failures: allow_failures:

View File

@ -13,11 +13,11 @@
} }
], ],
"require": { "require": {
"php": ">=5.3.0", "php": ">=5.5.0",
"ext-mbstring": "*" "ext-mbstring": "*"
}, },
"require-dev": { "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" "friendsofphp/php-cs-fixer": "^2.13"
}, },
"autoload": { "autoload": {