-
Notifications
You must be signed in to change notification settings - Fork 2
/
.travis.yml
35 lines (28 loc) · 844 Bytes
/
.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
language: php
env:
global:
- PHPCS=0
- RUN_TESTS=1
php:
- 5.4
- 5.5
- 5.6
- 7.0
- hhvm
sudo: false
matrix:
allow_failures:
- php: 7.0
include:
- php: 5.4
env: 'COMPOSER_FLAGS="--prefer-stable --prefer-lowest"'
- php: 5.6
env: PHPCS=1 RUN_TESTS=0
before_script:
- travis_retry composer self-update
- travis_retry composer update ${COMPOSER_FLAGS} --no-interaction --prefer-source
script:
- sh -c "if [ '$RUN_TESTS' = '1' ]; then phpunit --coverage-text --coverage-clover=coverage.clover; fi"
- sh -c "if [ '$PHPCS' = '1' ]; then vendor/bin/phpcs -p -n --extensions=php --standard=psr2 ./src ./tests; fi"
after_script:
- if [[ $TRAVIS_PHP_VERSION != 'hhvm' && $TRAVIS_PHP_VERSION != '7.0' ]]; then php vendor/bin/ocular code-coverage:upload --format=php-clover coverage.clover; fi