Activate redis
This commit is contained in:
parent
8f0afa6399
commit
b4624f87ae
3 changed files with 5 additions and 4 deletions
1
.github/workflows/php.yml
vendored
1
.github/workflows/php.yml
vendored
|
@ -91,6 +91,7 @@ jobs:
|
||||||
MYSQL_PASSWORD: test
|
MYSQL_PASSWORD: test
|
||||||
MYSQL_USER: test
|
MYSQL_USER: test
|
||||||
REDIS_PORT: ${{ job.services.redis.ports[6379] }}
|
REDIS_PORT: ${{ job.services.redis.ports[6379] }}
|
||||||
|
REDIS_HOST: 127.0.0.1
|
||||||
MEMCACHED_PORT: ${{ job.services.memcached.ports[11211] }}
|
MEMCACHED_PORT: ${{ job.services.memcached.ports[11211] }}
|
||||||
MEMCACHE_PORT: ${{ job.services.memcached.ports[11211] }}
|
MEMCACHE_PORT: ${{ job.services.memcached.ports[11211] }}
|
||||||
|
|
||||||
|
|
|
@ -37,7 +37,7 @@ class RedisCacheTest extends MemoryCacheTest
|
||||||
$configMock = Mockery::mock(IConfig::class);
|
$configMock = Mockery::mock(IConfig::class);
|
||||||
|
|
||||||
$host = $_SERVER['REDIS_HOST'] ?? 'localhost';
|
$host = $_SERVER['REDIS_HOST'] ?? 'localhost';
|
||||||
$port = $_SERVER['REDIS_PORT'] ?? null;
|
$port = $_SERVER['REDIS_PORT'] ?? 6379;
|
||||||
|
|
||||||
$configMock
|
$configMock
|
||||||
->shouldReceive('get')
|
->shouldReceive('get')
|
||||||
|
@ -51,7 +51,7 @@ class RedisCacheTest extends MemoryCacheTest
|
||||||
$configMock
|
$configMock
|
||||||
->shouldReceive('get')
|
->shouldReceive('get')
|
||||||
->with('system', 'redis_db', 0)
|
->with('system', 'redis_db', 0)
|
||||||
->andReturn(3);
|
->andReturn(0);
|
||||||
$configMock
|
$configMock
|
||||||
->shouldReceive('get')
|
->shouldReceive('get')
|
||||||
->with('system', 'redis_password')
|
->with('system', 'redis_password')
|
||||||
|
|
|
@ -38,7 +38,7 @@ class RedisCacheLockTest extends LockTest
|
||||||
$configMock = Mockery::mock(IConfig::class);
|
$configMock = Mockery::mock(IConfig::class);
|
||||||
|
|
||||||
$host = $_SERVER['REDIS_HOST'] ?? 'localhost';
|
$host = $_SERVER['REDIS_HOST'] ?? 'localhost';
|
||||||
$port = $_SERVER['REDIS_PORT'] ?? null;
|
$port = $_SERVER['REDIS_PORT'] ?? 6379;
|
||||||
|
|
||||||
$configMock
|
$configMock
|
||||||
->shouldReceive('get')
|
->shouldReceive('get')
|
||||||
|
@ -52,7 +52,7 @@ class RedisCacheLockTest extends LockTest
|
||||||
$configMock
|
$configMock
|
||||||
->shouldReceive('get')
|
->shouldReceive('get')
|
||||||
->with('system', 'redis_db', 0)
|
->with('system', 'redis_db', 0)
|
||||||
->andReturn(3);
|
->andReturn(0);
|
||||||
$configMock
|
$configMock
|
||||||
->shouldReceive('get')
|
->shouldReceive('get')
|
||||||
->with('system', 'redis_password')
|
->with('system', 'redis_password')
|
||||||
|
|
Loading…
Reference in a new issue