mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-01 14:30:32 +02:00
[ticket/15540] Fix tests and small fixes
PHPBB3-15540
This commit is contained in:
@@ -323,6 +323,11 @@ class phpbb_content_visibility_delete_post_test extends phpbb_database_test_case
|
||||
// Works as a workaround for tests
|
||||
$phpbb_container->set('attachment.manager', $attachment_delete);
|
||||
|
||||
$search_backend = $this->createMock(\phpbb\search\backend\search_backend_interface::class);
|
||||
$search_backend_factory = $this->createMock(\phpbb\search\search_backend_factory::class);
|
||||
$search_backend_factory->method('get_active')->willReturn($search_backend);
|
||||
$phpbb_container->set('search.backend_factory', $search_backend_factory);
|
||||
|
||||
delete_post($forum_id, $topic_id, $post_id, $data, $is_soft, $reason);
|
||||
|
||||
$result = $db->sql_query('SELECT post_id, post_visibility, post_delete_reason
|
||||
|
@@ -54,6 +54,13 @@ class phpbb_functions_user_delete_user_test extends phpbb_database_test_case
|
||||
'auth.provider_collection',
|
||||
$provider_collection
|
||||
);
|
||||
|
||||
$search_backend = $this->createMock(\phpbb\search\backend\search_backend_interface::class);
|
||||
$search_backend_factory = $this->createMock(\phpbb\search\search_backend_factory::class);
|
||||
$search_backend_factory->method('get_active')->willReturn($search_backend);
|
||||
$phpbb_container->set('search.backend_factory', $search_backend_factory);
|
||||
|
||||
|
||||
$phpbb_container->setParameter('tables.auth_provider_oauth_token_storage', 'phpbb_oauth_tokens');
|
||||
$phpbb_container->setParameter('tables.auth_provider_oauth_states', 'phpbb_oauth_states');
|
||||
$phpbb_container->setParameter('tables.auth_provider_oauth_account_assoc', 'phpbb_oauth_accounts');
|
||||
|
Reference in New Issue
Block a user