mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 14:00:31 +02:00
[feature/request-class] Add is_secure method to request for HTTPS
PHPBB3-9716
This commit is contained in:
@@ -117,6 +117,17 @@ class phpbb_request_test extends phpbb_test_case
|
||||
$this->assertTrue($this->request->is_ajax());
|
||||
}
|
||||
|
||||
public function test_is_secure()
|
||||
{
|
||||
$this->assertFalse($this->request->is_secure());
|
||||
|
||||
$this->request->enable_super_globals();
|
||||
$_SERVER['HTTPS'] = 'on';
|
||||
$this->request = new phpbb_request($this->type_cast_helper);
|
||||
|
||||
$this->assertTrue($this->request->is_secure());
|
||||
}
|
||||
|
||||
public function test_variable_names()
|
||||
{
|
||||
$expected = array('test', 'unset');
|
||||
|
Reference in New Issue
Block a user