[ticket/9657] Fix unit tests missing global container.

PHPBB3-9657
This commit is contained in:
Joas Schilling 2013-03-06 16:13:34 +01:00
parent 9bddf73d31
commit 1a17a3854f

View file

@ -262,13 +262,16 @@ 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;
global $auth, $cache, $config, $db, $phpbb_container;
$config['search_type'] = 'phpbb_mock_search';
$cache = new phpbb_mock_cache;
$db = $this->new_dbal();
set_config_count(null, null, null, new phpbb_config(array('num_posts' => 3, 'num_topics' => 1)));
$phpbb_container = new phpbb_mock_container_builder();
$phpbb_container->set('notification_manager', new phpbb_mock_notification_manager());
// Create auth mock
$auth = $this->getMock('phpbb_auth');
$auth->expects($this->any())