mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-07 20:08:53 +00:00
[ticket/17153] Use mocked user class in extension test
PHPBB3-17153
This commit is contained in:
parent
ad7721368c
commit
c495a26f98
1 changed files with 2 additions and 2 deletions
|
@ -32,7 +32,7 @@ class phpbb_template_extension_test extends phpbb_template_template_test_case
|
|||
$this->user->style['style_parent_id'] = 0;
|
||||
|
||||
global $auth, $request, $symfony_request, $user;
|
||||
$user = new phpbb_mock_user();
|
||||
$user = $this->createMock(\phpbb\user::class);
|
||||
$user->optionset('user_id', 2);
|
||||
$user->style['style_path'] = '';
|
||||
$user->data['user_id'] = 2;
|
||||
|
@ -92,7 +92,7 @@ class phpbb_template_extension_test extends phpbb_template_template_test_case
|
|||
$lang,
|
||||
$phpbb_container->get('avatar.manager'),
|
||||
$phpbb_path_helper,
|
||||
new \phpbb\user($lang, '\phpbb\datetime')
|
||||
$user
|
||||
);
|
||||
|
||||
$this->template_path = $this->test_path . '/templates';
|
||||
|
|
Loading…
Add table
Reference in a new issue