forked from wcomnisky/flagship-php-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
40 lines (32 loc) · 1.02 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
language: php
php:
- 7.3
- 7.4
- nightly
cache:
directories:
- $HOME/.composer/cache
before_install:
- mv ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/xdebug.ini{,.disabled} || echo "xdebug not available"
install: travis_retry composer install
script:
- ./vendor/bin/phpunit --testsuite=unit
- ./vendor/bin/phpunit --testsuite=functional
jobs:
allow_failures:
- php: nightly
include:
- stage: Metrics and quality
env: COVERAGE
before_script:
- mv ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/xdebug.ini{.disabled,}
- if [[ ! $(php -m | grep -si xdebug) ]]; then echo "xdebug required for code coverage"; exit 1; fi
script:
- ./vendor/bin/phpunit --testsuite=unit --coverage-clover ./clover.xml
after_script:
- wget https://scrutinizer-ci.com/ocular.phar
- php ocular.phar code-coverage:upload --format=php-clover ./clover.xml
- stage: Metrics and quality
env: CODE_STANDARD
script:
- ./vendor/bin/phpcs