mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Test for getExtension()
This commit is contained in:
parent
705d342080
commit
27bca14f86
@ -253,6 +253,12 @@ class HTTPRequestTest extends SapphireTest {
|
||||
$req = new SS_HTTPRequest('GET', '/home?test=1');
|
||||
$this->assertEquals('home?test=1', $req->getURL(true));
|
||||
$this->assertEquals('home', $req->getURL());
|
||||
|
||||
$req = new SS_HTTPRequest('GET', 'somefile.gif');
|
||||
$this->assertEquals('gif', $req->getExtension());
|
||||
|
||||
$req = new SS_HTTPRequest('GET', '.passwd');
|
||||
$this->assertEquals(null, $req->getExtension());
|
||||
}
|
||||
|
||||
public function testGetIPFromHeaderValue() {
|
||||
|
Loading…
Reference in New Issue
Block a user