-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
61 lines (55 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
60
61
language: php
cache:
directories:
- $HOME/.composer/cache
- $HOME/bin
- vendor
.steps:
- &disable-php-memory-limit |
echo "memory_limit=-1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
- &disable-xdebug-php-extension |
phpenv config-rm xdebug.ini || echo "xdebug not available"
- &update-project-dependencies |
composer update --prefer-dist --no-progress --no-suggest --ansi
- &install-php-coveralls |
composer require php-coveralls/php-coveralls --no-scripts
- &install-scrutinizer-ocular |
composer require scrutinizer/ocular --no-scripts
- &upload-coverage |
travis_retry vendor/bin/php-coveralls -vvv
travis_retry vendor/bin/ocular code-coverage:upload --format=php-clover build/logs/clover.xml
- &install-robo |
mkdir -p ${HOME}/bin || echo "directory exists"
export ROBO=${HOME}/bin/robo
[ -f "${ROBO}" ] && echo "installed" || wget -c https://github.com/kilip/robo/raw/site/robotheme/robo.phar -O ${ROBO}
chmod +x $ROBO
export PATH=${HOME}/bin:${PATH}
- &run-test |
robo test
- &run-test-coverage
robo coverage
jobs:
include:
- php: '7.0'
- php: '7.1'
- php: '7.2'
- php: '7.3'
env: COVERAGE=yes
before_cache:
- *install-php-coveralls
- *install-scrutinizer-ocular
script:
- *run-test-coverage
after_script:
- *upload-coverage
allow_failures:
- env: COVERAGE=yes
fast_finish: true
before_install:
- *disable-php-memory-limit
- *disable-xdebug-php-extension
- *install-robo
install:
- *update-project-dependencies
script:
- *run-test