[ticket/13207] Add notification manager mock to user_add method in tests

PHPBB3-13207
This commit is contained in:
Marc Alexander 2014-10-25 16:16:25 -07:00
parent 81ad381263
commit 0dcb874c09

View file

@ -556,12 +556,10 @@ class phpbb_functional_test_case extends phpbb_test_case
$cache = new phpbb_mock_null_cache; $cache = new phpbb_mock_null_cache;
$cache_driver = new \phpbb\cache\driver\null(); $cache_driver = new \phpbb\cache\driver\null();
$phpbb_container = $this->getMock('Symfony\Component\DependencyInjection\ContainerInterface'); $phpbb_container = new phpbb_mock_container_builder();
$phpbb_container $phpbb_container->set('cache.driver', $cache_driver);
->expects($this->any()) $phpbb_notifications = new phpbb_mock_notification_manager();
->method('get') $phpbb_container->set('notification_manager', $phpbb_notifications);
->with('cache.driver')
->will($this->returnValue($cache_driver));
if (!function_exists('utf_clean_string')) if (!function_exists('utf_clean_string'))
{ {