mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 22:10:45 +02:00
[ticket/13762] Moving language related functionality into a separate class
PHPBB3-13762
This commit is contained in:
@@ -27,7 +27,9 @@ class phpbb_log_add_test extends phpbb_database_test_case
|
||||
$db = $this->new_dbal();
|
||||
$cache = new phpbb_mock_cache;
|
||||
$phpbb_dispatcher = new phpbb_mock_event_dispatcher();
|
||||
$user = new \phpbb\user('\phpbb\datetime');
|
||||
$lang_loader = new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx);
|
||||
$lang = new \phpbb\language\language($lang_loader);
|
||||
$user = new \phpbb\user($lang, '\phpbb\datetime');
|
||||
$auth = $this->getMock('\phpbb\auth\auth');
|
||||
|
||||
$log = new \phpbb\log\log($db, $user, $auth, $phpbb_dispatcher, $phpbb_root_path, 'adm/', $phpEx, LOG_TABLE);
|
||||
@@ -56,7 +58,9 @@ class phpbb_log_add_test extends phpbb_database_test_case
|
||||
$db = $this->new_dbal();
|
||||
$cache = new phpbb_mock_cache;
|
||||
$phpbb_dispatcher = new phpbb_mock_event_dispatcher();
|
||||
$user = new \phpbb\user('\phpbb\datetime');
|
||||
$lang_loader = new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx);
|
||||
$lang = new \phpbb\language\language($lang_loader);
|
||||
$user = new \phpbb\user($lang, '\phpbb\datetime');
|
||||
$auth = $this->getMock('\phpbb\auth\auth');
|
||||
|
||||
$log = new \phpbb\log\log($db, $user, $auth, $phpbb_dispatcher, $phpbb_root_path, 'adm/', $phpEx, LOG_TABLE);
|
||||
|
@@ -30,7 +30,9 @@ class phpbb_log_delete_test extends phpbb_database_test_case
|
||||
|
||||
$db = $this->new_dbal();
|
||||
$phpbb_dispatcher = new phpbb_mock_event_dispatcher();
|
||||
$user = new \phpbb\user('\phpbb\datetime');
|
||||
$lang_loader = new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx);
|
||||
$lang = new \phpbb\language\language($lang_loader);
|
||||
$user = new \phpbb\user($lang, '\phpbb\datetime');
|
||||
$user->data['user_id'] = 1;
|
||||
$auth = $this->getMock('\phpbb\auth\auth');
|
||||
|
||||
|
@@ -161,7 +161,10 @@ class phpbb_log_function_add_log_test extends phpbb_database_test_case
|
||||
$db = $this->new_dbal();
|
||||
$cache = new phpbb_mock_cache;
|
||||
$phpbb_dispatcher = new phpbb_mock_event_dispatcher();
|
||||
$user = $this->getMock('\phpbb\user', array(), array('\phpbb\datetime'));
|
||||
$user = $this->getMock('\phpbb\user', array(), array(
|
||||
new \phpbb\language\language(new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx)),
|
||||
'\phpbb\datetime'
|
||||
));
|
||||
$auth = $this->getMock('\phpbb\auth\auth');
|
||||
|
||||
$phpbb_log = new \phpbb\log\log($db, $user, $auth, $phpbb_dispatcher, $phpbb_root_path, 'adm/', $phpEx, LOG_TABLE);
|
||||
|
Reference in New Issue
Block a user