File tree Expand file tree Collapse file tree 2 files changed +13
-4
lines changed Expand file tree Collapse file tree 2 files changed +13
-4
lines changed Original file line number Diff line number Diff line change 1
1
sudo : required
2
2
language : php
3
3
php : 7.0
4
- services : redis-server
5
4
before_install : phpize
6
5
install : ./configure --prefix=/usr && sudo make install
7
- before_script : echo 'extension = redis.so' >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
8
- script : php tests/TestRedis.php
6
+ before_script :
7
+ - gem install redis
8
+ - mkdir -p tests/nodes/ && echo >> tests/nodes/nodemap
9
+ - for PORT in $(seq 6379 6382); do redis-server --port $PORT --daemonize yes; done
10
+ - for PORT in $(seq 7000 7011); do redis-server --port $PORT --cluster-enabled yes --cluster-config-file $PORT.conf --daemonize yes; echo 127.0.0.1:$PORT >> tests/nodes/nodemap; done
11
+ - wget https://raw.githubusercontent.com/antirez/redis/unstable/src/redis-trib.rb
12
+ - echo yes | ruby redis-trib.rb create --replicas 3 127.0.0.1:7000 127.0.0.1:7001 127.0.0.1:7002 127.0.0.1:7003 127.0.0.1:7004 127.0.0.1:7005 127.0.0.1:7006 127.0.0.1:7007 127.0.0.1:7008 127.0.0.1:7009 127.0.0.1:7010 127.0.0.1:7011
13
+ - echo 'extension = redis.so' >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
14
+ script :
15
+ - php tests/TestRedis.php --class Redis
16
+ - php tests/TestRedis.php --class RedisArray
17
+ - php tests/TestRedis.php --class RedisCluster
Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ public function testReconnectSelect() { return $this->markTestSkipped(); }
35
35
36
36
/* Load our seeds on construction */
37
37
public function __construct () {
38
- $ str_nodemap_file = dirname (dirname ( $ _SERVER ['PHP_SELF ' ]) ) . '/nodes/nodemap ' ;
38
+ $ str_nodemap_file = dirname ($ _SERVER ['PHP_SELF ' ]) . '/nodes/nodemap ' ;
39
39
40
40
if (!file_exists ($ str_nodemap_file )) {
41
41
fprintf (STDERR , "Error: Can't find nodemap file for seeds! \n" );
You can’t perform that action at this time.
0 commit comments