-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.travis.yml
More file actions
62 lines (54 loc) · 1.31 KB
/
.travis.yml
File metadata and controls
62 lines (54 loc) · 1.31 KB
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
language: php
env:
- DOCKER_CACHE=/var/lib/docker/containers
cache:
directories:
- "$HOME/.composer/cache"
- $DOCKER_CACHE
matrix:
include:
- php: '7.1'
- php: '7.2'
- php: '7.2'
env: COVERAGE=yes
- php: '7.2'
env: INTEGRATION=yes
services:
- docker
allow_failures:
- php: '7.2'
env: COVERAGE=yes
- php: '7.2'
env: INTEGRATION=yes
fast_finish: true
before_install:
- echo "memory_limit=-1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
- |
if [[ $COVERAGE != yes ]]; then
phpenv config-rm xdebug.ini || echo "xdebug not available";
fi;
install:
- composer install --prefer-dist --no-progress --no-suggest --ansi
- |
if [[ $INTEGRATION = yes ]]; then
cp docker/custom.ini.dist docker/custom.ini;
docker-compose build;
docker-compose up -d;
sleep 5;
fi;
script:
- |
if [[ $INTEGRATION = yes ]]; then
./bin/run-behat -fprogress
elif [[ $COVERAGE = yes ]]; then
./vendor/bin/phpunit --coverage-clover build/logs/clover.xml;
else
./vendor/bin/phpunit;
fi;
after_script:
- |
if [[ $COVERAGE = yes ]]; then
bash <(curl -s https://codecov.io/bash) -s build/logs -f "*.xml";
wget https://scrutinizer-ci.com/ocular.phar;
php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml;
fi;