-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.travis.yml
59 lines (51 loc) · 1.62 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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
language: php
env:
global:
- COMPOSER_ARGS="--no-interaction"
matrix:
fast_finish: true
include:
- php: 7.2
env:
- DEPENDENCIES=""
- EXECUTE_CS_CHECK=true
- ARANGODB_VERSION=3.4.10
- php: 7.3
env:
- DEPENDENCIES=""
- EXECUTE_PHPSTAN=true
- ARANGODB_VERSION=3.5.5
- php: 7.4
env:
- DEPENDENCIES=""
- TEST_COVERAGE=true
- ARANGODB_VERSION=3.6.4
- php: nightly
env:
- DEPENDENCIES=""
- ARANGODB_VERSION=latest
allow_failures:
- php: nightly
addons:
hosts:
- arangodb
cache:
directories:
- $HOME/.composer/cache
- $HOME/.php-cs-fixer
- $HOME/.local
before_script:
- mkdir -p "$HOME/.php-cs-fixer"
- composer self-update
- composer update --prefer-dist $DEPENDENCIES
- ./test/.travis/setup_arangodb.sh
script:
- if [[ $EXECUTE_PHPSTAN == 'true' ]]; then ./vendor/bin/phpstan analyze -l max -c ./phpstan.installer.neon ./src; fi
- if [[ $EXECUTE_CS_CHECK == 'true' ]]; then ./vendor/bin/phpcs; fi
- if [[ $EXECUTE_CS_CHECK == 'true' ]]; then ./vendor/bin/docheader check src/ tests/; fi
- if [[ $TEST_COVERAGE == 'true' ]]; then php -dzend_extension=xdebug.so ./vendor/bin/phpunit --coverage-text --coverage-clover ./build/logs/clover.xml; fi
- if [[ $TEST_COVERAGE != 'true' ]]; then php ./vendor/bin/phpunit; fi
after_script:
- if [[ $TEST_COVERAGE == 'true' ]]; then travis_retry php vendor/bin/php-coveralls -v ; fi
- if [[ $TEST_COVERAGE == 'true' ]]; then wget https://scrutinizer-ci.com/ocular.phar ; fi
- if [[ $TEST_COVERAGE == 'true' ]]; then php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml ; fi