Skip to content

Commit

Permalink
Merge pull request #15 from phil-davis/test-with-php-8.0
Browse files Browse the repository at this point in the history
Test with PHP 8.0
  • Loading branch information
phil-davis authored Oct 3, 2020
2 parents e893c7d + 9ad67d3 commit e28b39e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
15 changes: 13 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,37 @@ php:

env:
global:
- RUN_PHPCSFIXER="TRUE"
- RUN_PHPUNIT="TRUE"
- RUN_PHPSTAN="FALSE"
matrix:
- PREFER_LOWEST="" REPORT_COVERAGE="TRUE" WITH_COVERAGE="--coverage-clover=coverage.xml"
- PREFER_LOWEST="--prefer-lowest" REPORT_COVERAGE="FALSE" WITH_COVERAGE=""

matrix:
include:
- name: 'PHP8'
dist: focal
php: nightly
env:
- RUN_PHPCSFIXER="FALSE"
- REPORT_COVERAGE="FALSE"
- name: 'PHPStan'
php: 7.4
env:
- RUN_PHPCSFIXER="FALSE"
- RUN_PHPUNIT="FALSE"
- RUN_PHPSTAN="TRUE"
- REPORT_COVERAGE="FALSE"
fast_finish: true

before_script:
- if [ $RUN_PHPCSFIXER == "FALSE" ]; then composer remove --dev friendsofphp/php-cs-fixer; fi
- composer update $PREFER_LOWEST

script:
- if [ $RUN_PHPSTAN == "FALSE" ]; then php vendor/bin/php-cs-fixer fix --dry-run --diff; fi
- if [ $RUN_PHPSTAN == "FALSE" ]; then php vendor/bin/phpunit --configuration tests/phpunit.xml $WITH_COVERAGE; fi
- if [ $RUN_PHPCSFIXER == "TRUE" ]; then php vendor/bin/php-cs-fixer fix --dry-run --diff; fi
- if [ $RUN_PHPUNIT == "TRUE" ]; then php vendor/bin/phpunit --configuration tests/phpunit.xml $WITH_COVERAGE; fi
- if [ $RUN_PHPSTAN == "TRUE" ]; then composer phpstan; fi

after_success:
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"homepage": "http://sabre.io/dav/",
"license": "BSD-3-Clause",
"require": {
"php" : "^7.1",
"php" : "^7.1 || ^8.0",
"sabre/xml" : "^2.0"
},
"authors": [
Expand Down

0 comments on commit e28b39e

Please sign in to comment.