PhpSpreadsheet/.travis.yml

57 lines
1.4 KiB
YAML
Raw Normal View History

2012-11-23 10:51:34 +00:00
language: php
2019-12-19 10:44:12 +00:00
dist: bionic
2012-11-23 10:51:34 +00:00
php:
2017-11-02 07:02:42 +00:00
- 7.2
2018-10-14 13:20:18 +00:00
- 7.3
- 7.4
- nightly
cache:
directories:
- vendor
- $HOME/.composer/cache
2015-05-11 10:30:15 +00:00
before_script:
2018-01-28 09:07:51 +00:00
# Deactivate xdebug
2020-08-09 12:33:13 +00:00
- if [[ $TRAVIS_PHP_VERSION != nightly ]]; then phpenv config-rm xdebug.ini; fi
- if [[ $TRAVIS_PHP_VERSION == nightly ]]; then cp composer.php8.json composer.json; fi
- composer install --ignore-platform-reqs
2012-11-23 10:51:34 +00:00
script:
2020-07-25 21:17:26 +00:00
- ./vendor/bin/phpunit --color=always --coverage-text
2018-01-28 09:07:51 +00:00
allow_failures:
- php: nightly
2018-01-28 09:07:51 +00:00
jobs:
include:
- stage: Code style
php: 7.4
2018-01-28 09:07:51 +00:00
script:
- ./vendor/bin/php-cs-fixer fix --diff --verbose --dry-run
2020-07-26 06:05:54 +00:00
- ./vendor/bin/phpcs
2016-08-16 14:38:24 +00:00
2018-01-28 09:07:51 +00:00
- stage: Coverage
php: 7.4
2018-01-28 09:07:51 +00:00
script:
- pecl install pcov
- ./vendor/bin/phpunit --coverage-clover coverage-clover.xml
2018-01-28 09:07:51 +00:00
after_script:
- wget https://scrutinizer-ci.com/ocular.phar
- php ocular.phar code-coverage:upload --format=php-clover tests/coverage-clover.xml
- stage: API documentations
if: tag is present
php: 7.4
before_script:
- curl -LO https://github.com/phpDocumentor/phpDocumentor/releases/download/v3.0.0-rc/phpDocumentor.phar
script:
- php phpDocumentor.phar --directory src/ --target docs/api
deploy:
provider: pages
skip-cleanup: true
local-dir: docs/api
github-token: $GITHUB_TOKEN