mirror of
https://github.com/phpbb/phpbb.git
synced 2025-09-01 20:33:16 +02:00
[ticket/11700] Move all recent code to namespaces
PHPBB3-11700
This commit is contained in:
@@ -39,13 +39,13 @@ abstract class phpbb_security_test_base extends phpbb_test_case
|
||||
$request = new phpbb_mock_request(array(), array(), array(), $server);
|
||||
|
||||
// Set no user and trick a bit to circumvent errors
|
||||
$user = new phpbb_user();
|
||||
$user = new \phpbb\user();
|
||||
$user->lang = true;
|
||||
$user->browser = $server['HTTP_USER_AGENT'];
|
||||
$user->referer = '';
|
||||
$user->forwarded_for = '';
|
||||
$user->host = $server['HTTP_HOST'];
|
||||
$user->page = phpbb_session::extract_current_page($phpbb_root_path);
|
||||
$user->page = \phpbb\session::extract_current_page($phpbb_root_path);
|
||||
}
|
||||
|
||||
protected function tearDown()
|
||||
|
@@ -28,12 +28,12 @@ class phpbb_security_extract_current_page_test extends phpbb_security_test_base
|
||||
{
|
||||
global $request;
|
||||
|
||||
$request->merge(phpbb_request_request_interface::SERVER, array(
|
||||
$request->merge(\phpbb\request\request_interface::SERVER, array(
|
||||
'PHP_SELF' => $url,
|
||||
'QUERY_STRING' => $query_string,
|
||||
));
|
||||
|
||||
$result = phpbb_session::extract_current_page('./');
|
||||
$result = \phpbb\session::extract_current_page('./');
|
||||
|
||||
$label = 'Running extract_current_page on ' . $query_string . ' with PHP_SELF filled.';
|
||||
$this->assertEquals($expected, $result['query_string'], $label);
|
||||
@@ -46,12 +46,12 @@ class phpbb_security_extract_current_page_test extends phpbb_security_test_base
|
||||
{
|
||||
global $request;
|
||||
|
||||
$request->merge(phpbb_request_request_interface::SERVER, array(
|
||||
$request->merge(\phpbb\request\request_interface::SERVER, array(
|
||||
'PHP_SELF' => $url,
|
||||
'QUERY_STRING' => $query_string,
|
||||
));
|
||||
|
||||
$result = phpbb_session::extract_current_page('./');
|
||||
$result = \phpbb\session::extract_current_page('./');
|
||||
|
||||
$label = 'Running extract_current_page on ' . $query_string . ' with REQUEST_URI filled.';
|
||||
$this->assertEquals($expected, $result['query_string'], $label);
|
||||
|
Reference in New Issue
Block a user