mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 05:50:42 +02:00
[ticket/9983] Add redis cache driver tests.
In order to not overwrite data in default redis store, at least one of redis host or post must be explicitly specified. Redis cache driver constructor has been modified to accept host and port as parameters. This was not added to public API as there are more parameters being passed via global constants. PHPBB3-9983
This commit is contained in:
@@ -91,6 +91,15 @@ class phpbb_test_case_helpers
|
||||
{
|
||||
$config['phpbb_functional_url'] = $phpbb_functional_url;
|
||||
}
|
||||
|
||||
if (isset($redis_host))
|
||||
{
|
||||
$config['redis_host'] = $redis_host;
|
||||
}
|
||||
if (isset($redis_port))
|
||||
{
|
||||
$config['redis_port'] = $redis_port;
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($_SERVER['PHPBB_TEST_DBMS']))
|
||||
@@ -113,6 +122,16 @@ class phpbb_test_case_helpers
|
||||
));
|
||||
}
|
||||
|
||||
if (isset($_SERVER['PHPBB_TEST_REDIS_HOST']))
|
||||
{
|
||||
$config['redis_host'] = $_SERVER['PHPBB_TEST_REDIS_HOST'];
|
||||
}
|
||||
|
||||
if (isset($_SERVER['PHPBB_TEST_REDIS_PORT']))
|
||||
{
|
||||
$config['redis_port'] = $_SERVER['PHPBB_TEST_REDIS_PORT'];
|
||||
}
|
||||
|
||||
return $config;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user