aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMateBartus <mate.bartus@gmail.com>2015-04-14 02:31:23 +0200
committerMateBartus <mate.bartus@gmail.com>2015-05-02 13:37:12 +0200
commit179a4700221aa49071b07d638c44b9326c7a14a8 (patch)
tree3dd78a5fb9353afabaa629e8dae58b7f8d99c144 /tests/avatar
parentMerge pull request #3565 from MateBartus/ticket/13793 (diff)
downloadphpbb-179a4700221aa49071b07d638c44b9326c7a14a8.tar.gz
phpbb-179a4700221aa49071b07d638c44b9326c7a14a8.tar.bz2
phpbb-179a4700221aa49071b07d638c44b9326c7a14a8.zip
[ticket/13762] Moving language related functionality into a separate class
PHPBB3-13762
Diffstat (limited to 'tests/avatar')
-rw-r--r--tests/avatar/manager_test.php11
1 files changed, 9 insertions, 2 deletions
diff --git a/tests/avatar/manager_test.php b/tests/avatar/manager_test.php
index 638ba0aaff..71f40c0b13 100644
--- a/tests/avatar/manager_test.php
+++ b/tests/avatar/manager_test.php
@@ -94,7 +94,9 @@ class phpbb_avatar_manager_test extends \phpbb_database_test_case
// Set up avatar manager
$this->manager = new \phpbb\avatar\manager($this->config, $avatar_drivers, $phpbb_container);
$this->db = $this->new_dbal();
- $this->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);
+ $this->user = new \phpbb\user($lang, '\phpbb\datetime');
}
protected function avatar_drivers()
@@ -277,7 +279,12 @@ class phpbb_avatar_manager_test extends \phpbb_database_test_case
public function test_localize_errors()
{
- $user = $this->getMock('\phpbb\user', array(), array('\phpbb\datetime'));
+ global $phpbb_root_path, $phpEx;
+
+ $user = $this->getMock('\phpbb\user', array(), array(
+ new \phpbb\language\language(new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx)),
+ '\phpbb\datetime')
+ );
$lang_array = array(
array('FOOBAR_OFF', 'foobar_off'),
array('FOOBAR_EXPLAIN', 'FOOBAR_EXPLAIN %s'),