mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-02 12:34:59 +02:00
[ticket/12746] Init phpbb_dispatcher being used by delete_post()
PHPBB3-12746
This commit is contained in:
parent
b855f5fc6a
commit
752b5b6628
@ -266,7 +266,7 @@ class phpbb_content_visibility_delete_post_test extends phpbb_database_test_case
|
||||
*/
|
||||
public function test_delete_post($forum_id, $topic_id, $post_id, $data, $is_soft, $reason, $expected_posts, $expected_topic, $expected_forum)
|
||||
{
|
||||
global $auth, $cache, $config, $db, $phpbb_container, $phpbb_root_path, $phpEx;
|
||||
global $auth, $cache, $config, $db, $phpbb_container, $phpbb_dispatcher, $phpbb_root_path, $phpEx;
|
||||
|
||||
$config['search_type'] = 'phpbb_mock_search';
|
||||
$cache = new phpbb_mock_cache;
|
||||
@ -283,6 +283,8 @@ class phpbb_content_visibility_delete_post_test extends phpbb_database_test_case
|
||||
)));
|
||||
$user = $this->getMock('\phpbb\user');
|
||||
|
||||
$phpbb_dispatcher = new phpbb_mock_event_dispatcher();
|
||||
|
||||
$phpbb_container = new phpbb_mock_container_builder();
|
||||
$phpbb_container->set('notification_manager', new phpbb_mock_notification_manager());
|
||||
$phpbb_container->set('content.visibility', new \phpbb\content_visibility($auth, $db, $user, $phpbb_root_path, $phpEx, FORUMS_TABLE, POSTS_TABLE, TOPICS_TABLE, USERS_TABLE));
|
||||
|
Loading…
x
Reference in New Issue
Block a user