-
Notifications
You must be signed in to change notification settings - Fork 3
/
.travis.yml
59 lines (47 loc) · 1.44 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
dist: xenial
sudo: required
language: php
cache:
directories:
- .phpunit
- "$HOME/.composer/cache"
git:
depth: 2
env:
global:
- SYMFONY_PHPUNIT_DISABLE_RESULT_CACHE=1
matrix:
fast_finish: true
include:
- php: 7.1
- php: 7.2
env: ENABLE_IGBINARY=true
- php: 7.3
env: CHECK_CS=true
services:
- redis-server
# - memcached
- docker
# test only master + stable (+ Pull requests)
branches:
only:
- master
- /^\d.\d+$/
before_install:
- phpenv config-rm xdebug.ini
- |
# Start Redis cluster
docker pull grokzen/redis-cluster:5.0.4
docker run -d -p 7000:7000 -p 7001:7001 -p 7002:7002 -p 7003:7003 -p 7004:7004 -p 7005:7005 --name redis-cluster grokzen/redis-cluster:5.0.4
export REDIS_CLUSTER_HOSTS='localhost:7000 localhost:7001 localhost:7002 localhost:7003 localhost:7004 localhost:7005'
install:
# - echo "extension = memcached.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
- echo "extension = redis.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
- if [ "$ENABLE_IGBINARY" != "" ] ; then pecl install igbinary ; fi
- if [ "$ENABLE_LZF" != "" ] ; then printf "no\n" | pecl install lzf ; fi
- travis_retry composer install --prefer-dist --no-interaction
script:
- composer test
- if [ "$CHECK_CS" != "" ]; then ./vendor/bin/php-cs-fixer fix -v --dry-run --diff --show-progress=estimating; fi
notifications:
email: false