-
Notifications
You must be signed in to change notification settings - Fork 8
/
.travis.yml
64 lines (55 loc) · 2.51 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
60
61
62
63
64
sudo: false
language: php
env:
global:
- secure: "q+yZZRkLtxe0KE7StvQYZFobuHOixuPfcQJJ/pbTtvEBNLMWqUZo+JBiGiDzamh9p3mW7eZ7Safpm7KXwTrsr4zOo+rkwWcPWD2yqX10n9kndKsYKXOi3wpX7z16DxtX0dT8V6+8R6Y/JXb7KN71DDcTOGed8wEn36MgIR0gYGNKDAK1UbqUhOBxhKIPnjodPUuQpFtNf4hiOp67wZ9BZGaNNniCreMkTkAFnY3VXnx0UuxvU3LCVlAXarOV8Pbyll0AnAYRMaOrh2QJPhQKSMxIWhTx0PlRce0a7rfarZ3x0NJBY41IlYG+k4crFVUTZ54s29xunTpGzHofcdUKYJ0iAMLG2g3qVtz9oyWNJ3qC7NAD9YM8HyPZ8WO09emLjdRZ8Pjspm5XqlzROaLp53KOmZL4PTuF7fIHuPFU1zJN79Z/C+4ikbXVu5pu0ERWa8HWhEDrHMTa+xZuG6PK131joqKSaNe+a5AgYBXAvVxkmSeDrARzYKb7hjORV7b4T0XeFfuF/aJFQJRtH79avDSJUoNM/I0HH3CS2mc3vxmlXPdH08Y7/dr8SQ8EuQHCWwiXIJI6Z9S7/EPMbb3C6lA2W76ukKY6eghwoVn2q+b44y6zI8qGA4mZkrgLK33JkGUr+DorwFa6nkZuAvFOy4FhySE4WaMHZRs9q27DQnA="
branches:
except:
- /^release-.*$/
cache:
directories:
- $HOME/.composer/cache
- $HOME/.php-cs-fixer
- $HOME/.local
matrix:
fast_finish: true
include:
- php: 7.1
env:
- EXECUTE_DOCHEADER_CHECK=true
- php: 7.2
env:
- DEPLOY_DOCS="$(if [[ $TRAVIS_BRANCH == 'master' && $TRAVIS_PULL_REQUEST == 'false' ]]; then echo -n 'true' ; else echo -n 'false' ; fi)"
- php: 7.3
env:
- EXECUTE_CS_CHECK=true
- php: 7.4
env:
- TEST_COVERAGE=true
- php: 8.0
allow_failures:
- php: 8.0
before_install:
- mkdir -p "$HOME/.php-cs-fixer"
- if [[ $TEST_COVERAGE != 'true' ]]; then phpenv config-rm xdebug.ini || return 0 ; fi
- composer self-update
- composer update --prefer-dist
script:
- if [[ $TEST_COVERAGE == 'true' ]]; then ./vendor/bin/phpunit --coverage-text --coverage-clover ./build/logs/clover.xml; fi
- if [[ $TEST_COVERAGE != 'true' ]]; then ./vendor/bin/phpunit --no-coverage ; fi
- if [[ $EXECUTE_CS_CHECK == 'true' ]]; then ./vendor/bin/phpcs ; fi
- if [[ $EXECUTE_DOCHEADER_CHECK == 'true' ]]; then ./vendor/bin/docheader check src/ test/ ; fi
- if [[ $DEPLOY_DOCS == 'true' ]]; then vendor/bin/bookdown doc/bookdown.json --root-href=https://sandrokeil.github.io/interop-config/ ; fi
deploy:
provider: pages
skip-cleanup: true
github-token: $GITHUB_TOKEN
keep-history: true
local-dir: doc/html
on:
branch: master
condition: $DEPLOY_DOCS = 'true'
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