mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-08 15:42:48 +08:00
增加inputTest方法
This commit is contained in:
@@ -127,6 +127,15 @@ class inputTest extends \PHPUnit_Framework_TestCase
|
|||||||
$this->assertEquals(true, Input::post('d/b'));
|
$this->assertEquals(true, Input::post('d/b'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function testHasValue()
|
||||||
|
{
|
||||||
|
$_GET['name'] = 'value';
|
||||||
|
$this->assertEquals(true, Input::get('?name'));
|
||||||
|
$this->assertEquals(false, Input::get('?id'));
|
||||||
|
$this->assertEquals(true, Input::get('?get.name'));
|
||||||
|
$this->assertEquals(false, Input::get('?get.id'));
|
||||||
|
}
|
||||||
|
|
||||||
public function testSuperglobals()
|
public function testSuperglobals()
|
||||||
{
|
{
|
||||||
Input::setFilter('trim');
|
Input::setFilter('trim');
|
||||||
|
|||||||
Reference in New Issue
Block a user