From e4e514197874003dca3a21867c802133d1614e77 Mon Sep 17 00:00:00 2001 From: Marc Alexander Date: Mon, 14 Sep 2015 17:52:10 +0200 Subject: [PATCH] [ticket/652] Fix test failures caused by latest changes to phpBB's master B3P-652 --- tests/unit/acp/move_module_test.php | 2 +- tests/unit/controller/helper_test.php | 2 +- tests/unit/controller/main_test.php | 2 +- tests/unit/event/listener_test.php | 8 +++++--- tests/unit/modules/calendar_test.php | 2 +- tests/unit/modules/welcome_test.php | 3 ++- tests/unit/portal/modules_manager_confirm_box_test.php | 2 +- tests/unit/portal/modules_manager_test.php | 2 +- 8 files changed, 13 insertions(+), 10 deletions(-) diff --git a/tests/unit/acp/move_module_test.php b/tests/unit/acp/move_module_test.php index 9f142c91..d532cb08 100644 --- a/tests/unit/acp/move_module_test.php +++ b/tests/unit/acp/move_module_test.php @@ -112,7 +112,7 @@ class phpbb_acp_move_module_test extends \board3\portal\tests\testframework\data new \phpbb\symfony_request( new \phpbb_mock_request() ), - new \phpbb\filesystem(), + new \phpbb\filesystem\filesystem(), new \phpbb_mock_request(), $phpbb_root_path, $phpEx diff --git a/tests/unit/controller/helper_test.php b/tests/unit/controller/helper_test.php index 12ccb37e..31b92c47 100644 --- a/tests/unit/controller/helper_test.php +++ b/tests/unit/controller/helper_test.php @@ -52,7 +52,7 @@ class helper_test extends \board3\portal\tests\testframework\test_case new \phpbb\symfony_request( new \phpbb_mock_request() ), - new \phpbb\filesystem(), + new \phpbb\filesystem\filesystem(), new \phpbb_mock_request(), $this->phpbb_root_path, $this->php_ext diff --git a/tests/unit/controller/main_test.php b/tests/unit/controller/main_test.php index 6588604a..8d01ed58 100644 --- a/tests/unit/controller/main_test.php +++ b/tests/unit/controller/main_test.php @@ -35,7 +35,7 @@ class main_test extends \board3\portal\tests\testframework\database_test_case new \phpbb\symfony_request( new \phpbb_mock_request() ), - new \phpbb\filesystem(), + new \phpbb\filesystem\filesystem(), new \phpbb_mock_request(), $phpbb_root_path, $phpEx diff --git a/tests/unit/event/listener_test.php b/tests/unit/event/listener_test.php index 1dd2dc5c..2f3f615c 100644 --- a/tests/unit/event/listener_test.php +++ b/tests/unit/event/listener_test.php @@ -58,7 +58,7 @@ class listener_test extends \phpbb_template_template_test_case $manager = new \phpbb_mock_extension_manager(dirname(__FILE__) . '/', array()); $finder = new \phpbb\finder( - new \phpbb\filesystem(), + new \phpbb\filesystem\filesystem(), dirname(__FILE__) . '/', new \phpbb_mock_cache() ); @@ -79,13 +79,15 @@ class listener_test extends \phpbb_template_template_test_case $router = new \phpbb_mock_router($container, $filesystem, dirname(__FILE__) . '/', 'php', PHPBB_ENVIRONMENT, $manager); $router->find_routing_files($manager->all_enabled(false)); $router->find(dirname(__FILE__) . '/'); - $this->controller_helper = new mock_controller_helper($this->template, $this->user, $this->config, $router, new \phpbb\symfony_request($request), $request, new \phpbb\filesystem(), '', 'php', dirname(__FILE__) . '/'); + $symfony_request = new \phpbb\symfony_request($request); + $routing_helper = new \phpbb\routing\helper($this->config, $router, $symfony_request, $request, $filesystem, $phpbb_root_path, 'php'); + $this->controller_helper = new mock_controller_helper($this->template, $this->user, $this->config, $symfony_request, $request, $routing_helper); $this->path_helper = new \phpbb\path_helper( new \phpbb\symfony_request( new \phpbb_mock_request() ), - new \phpbb\filesystem(), + new \phpbb\filesystem\filesystem(), new \phpbb_mock_request(), $this->phpbb_root_path, $this->php_ext diff --git a/tests/unit/modules/calendar_test.php b/tests/unit/modules/calendar_test.php index 1a08790d..3cbfe230 100644 --- a/tests/unit/modules/calendar_test.php +++ b/tests/unit/modules/calendar_test.php @@ -44,7 +44,7 @@ class phpbb_unit_modules_calendar_test extends \board3\portal\tests\testframewor new \phpbb\symfony_request( new \phpbb_mock_request() ), - new \phpbb\filesystem(), + new \phpbb\filesystem\filesystem(), new \phpbb_mock_request(), $phpbb_root_path, 'php' diff --git a/tests/unit/modules/welcome_test.php b/tests/unit/modules/welcome_test.php index 75c112cb..e8eaf1b8 100644 --- a/tests/unit/modules/welcome_test.php +++ b/tests/unit/modules/welcome_test.php @@ -40,7 +40,7 @@ class phpbb_unit_modules_welcome_test extends \board3\portal\tests\testframework parent::setUp(); global $cache, $phpbb_root_path, $phpEx, $phpbb_dispatcher, $request, $config, $phpbb_container; - $config = $this->config = new \phpbb\config\config(array()); + $config = $this->config = new \phpbb\config\config(array('allowed_schemes_links' => 'http,https,ftp')); $this->request = new \phpbb_mock_request(); $request = $this->request; $this->template = new \board3\portal\tests\mock\template($this); @@ -77,6 +77,7 @@ class phpbb_unit_modules_welcome_test extends \board3\portal\tests\testframework new \phpbb\textformatter\data_access($this->db, BBCODES_TABLE, SMILIES_TABLE, STYLES_TABLE, WORDS_TABLE, $phpbb_root_path . 'styles/'), new \phpbb\cache\driver\dummy(), $phpbb_dispatcher, + $config, $phpbb_root_path . 'cache', '_text_formatter_parser', '_text_formatter_renderer' diff --git a/tests/unit/portal/modules_manager_confirm_box_test.php b/tests/unit/portal/modules_manager_confirm_box_test.php index db4030bf..777eed29 100644 --- a/tests/unit/portal/modules_manager_confirm_box_test.php +++ b/tests/unit/portal/modules_manager_confirm_box_test.php @@ -94,7 +94,7 @@ class modules_manager_confirm_box_test extends \board3\portal\tests\testframewor new \phpbb\symfony_request( new \phpbb_mock_request() ), - new \phpbb\filesystem(), + new \phpbb\filesystem\filesystem(), new \phpbb_mock_request(), $phpbb_root_path, $phpEx diff --git a/tests/unit/portal/modules_manager_test.php b/tests/unit/portal/modules_manager_test.php index fd317851..0f7638bd 100644 --- a/tests/unit/portal/modules_manager_test.php +++ b/tests/unit/portal/modules_manager_test.php @@ -89,7 +89,7 @@ class board3_portal_modules_manager_test extends \board3\portal\tests\testframew new \phpbb\symfony_request( new \phpbb_mock_request() ), - new \phpbb\filesystem(), + new \phpbb\filesystem\filesystem(), new \phpbb_mock_request(), $phpbb_root_path, $phpEx