Welcome to mirror list, hosted at ThFree Co, Russian Federation.

.travis.yml - github.com/phpredis/phpredis.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 124c0727ec5cfe5ac445aae4b121f598ff4e02c6 (plain)
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
65
66
67
language: php
php:
  - 7.0
  - 7.1
  - 7.2
  - 7.3
  - 7.4
  - nightly
env: CC=gcc
matrix:
  allow_failures:
    - php: 7.3
      env: CC=clang
    - php: 7.4
      env: CC=clang
    - php: nightly
  include:
    - php: 7.0
      env: CC=clang
    - php: 7.1
      env: CC=clang
    - php: 7.2
      env: CC=clang
    - php: 7.3
      env: CC=clang
    - php: 7.4
      env: CC=clang
addons:
  apt:
    update: true
    sources:
    - sourceline: ppa:redislabs/redis
    packages:
    - clang
    - libzstd1-dev
    - liblz4-dev
    - pkg-config
    - valgrind
    - stunnel
    - redis
before_install:
  - phpize
  - CFGARGS="--enable-redis-lzf --enable-redis-zstd --enable-redis-lz4 --with-liblz4"
  - pecl install igbinary && CFGARGS="$CFGARGS --enable-redis-igbinary" || true
  - pecl install msgpack && CFGARGS="$CFGARGS --enable-redis-msgpack" || true
  - ./configure $CFGARGS
install: make install
before_script:
  - mkdir -p tests/nodes/ && echo > tests/nodes/nodemap
  - redis-server --port 0 --daemonize yes --aclfile tests/users.acl --unixsocket /tmp/redis.sock
  - for PORT in $(seq 6379 6382) $(seq 32767 32769); do redis-server --port $PORT --daemonize yes --aclfile tests/users.acl; done
  - for PORT in $(seq 7000 7011); do redis-server --port $PORT --cluster-enabled yes --cluster-config-file $PORT.conf --daemonize yes --aclfile tests/users.acl; echo 127.0.0.1:$PORT >> tests/nodes/nodemap; done
  - for PORT in $(seq 26379 26380); do wget download.redis.io/redis-stable/sentinel.conf -O $PORT.conf; echo sentinel auth-pass mymaster phpredis >> $PORT.conf; redis-server $PORT.conf --port $PORT --daemonize yes --sentinel; done
  - echo yes | redis-cli --cluster create $(seq -f 127.0.0.1:%g 7000 7011) --cluster-replicas 3 --user phpredis -a phpredis
  - echo 'extension = redis.so' >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
  - openssl req -x509 -newkey rsa:1024 -nodes -keyout stunnel.key -out stunnel.pem -days 1 -subj '/CN=localhost'
  - echo -e 'key=stunnel.key\ncert=stunnel.pem\npid=/tmp/stunnel.pid\n[redis]\naccept=6378\nconnect=6379' > stunnel.conf
  - stunnel stunnel.conf
script:
  - php tests/TestRedis.php --class Redis --user phpredis --auth phpredis
  - php tests/TestRedis.php --class RedisArray --user phpredis --auth phpredis
  - php tests/TestRedis.php --class RedisCluster --user phpredis --auth phpredis
  - php tests/TestRedis.php --class RedisSentinel --auth phpredis
  - USE_ZEND_ALLOC=0 valgrind --error-exitcode=1 php tests/TestRedis.php --class Redis --user phpredis --auth phpredis
  - USE_ZEND_ALLOC=0 valgrind --error-exitcode=1 php tests/TestRedis.php --class RedisArray --user phpredis --auth phpredis
  - USE_ZEND_ALLOC=0 valgrind --error-exitcode=1 php tests/TestRedis.php --class RedisCluster --user phpredis --auth phpredis
  - USE_ZEND_ALLOC=0 valgrind --error-exitcode=1 php tests/TestRedis.php --class RedisSentinel --auth phpredis