mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-10 18:54:08 +02:00
Merge branch '3.3.x'
This commit is contained in:
31
tests/mock/dummy_router.php
Normal file
31
tests/mock/dummy_router.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
/**
|
||||
*
|
||||
* This file is part of the phpBB Forum Software package.
|
||||
*
|
||||
* @copyright (c) phpBB Limited <https://www.phpbb.com>
|
||||
* @license GNU General Public License, version 2 (GPL-2.0)
|
||||
*
|
||||
* For full copyright and license information, please see
|
||||
* the docs/CREDITS.txt file.
|
||||
*
|
||||
*/
|
||||
|
||||
class phpbb_mock_dummy_router extends phpbb_mock_router
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
}
|
||||
|
||||
public function get_matcher()
|
||||
{
|
||||
$this->create_new_url_matcher();
|
||||
return parent::get_matcher();
|
||||
}
|
||||
|
||||
public function get_generator()
|
||||
{
|
||||
$this->create_new_url_generator();
|
||||
return parent::get_generator();
|
||||
}
|
||||
}
|
@@ -11,6 +11,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
class phpbb_mock_extension_manager extends \phpbb\extension\manager
|
||||
{
|
||||
public function __construct($phpbb_root_path, $extensions = array(), $container = null)
|
||||
@@ -20,10 +21,9 @@ class phpbb_mock_extension_manager extends \phpbb\extension\manager
|
||||
$lang = new \phpbb\language\language(new \phpbb\language\language_file_loader($phpbb_root_path, $phpEx));
|
||||
$this->phpbb_root_path = $phpbb_root_path;
|
||||
$this->extensions = $extensions;
|
||||
$this->filesystem = new \phpbb\filesystem\filesystem();
|
||||
$this->container = $container;
|
||||
$this->config = new \phpbb\config\config(array());
|
||||
$this->user = new \phpbb\user($lang,'\phpbb\datetime');
|
||||
$this->finder_factory = new \phpbb\finder\factory(null, false, $this->phpbb_root_path, $phpEx);
|
||||
$this->router = new phpbb_mock_dummy_router();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user