mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
fixed expected and result order in asserts, also added extra test
This commit is contained in:
parent
836f913a64
commit
6d3c659260
1 changed files with 8 additions and 1 deletions
|
@ -172,7 +172,7 @@ class CakeRequestTest extends CakeTestCase {
|
|||
'Article' => array('title')
|
||||
));
|
||||
$request = new CakeRequest('some/path');
|
||||
$this->assertEquals($request->data, $_POST['data']);
|
||||
$this->assertEquals($_POST['data'], $request->data);
|
||||
|
||||
$_POST = array('one' => 1, 'two' => 'three');
|
||||
$request = new CakeRequest('some/path');
|
||||
|
@ -197,6 +197,13 @@ class CakeRequestTest extends CakeTestCase {
|
|||
));
|
||||
$request = new CakeRequest('some/path');
|
||||
$this->assertEquals($request->data, $_POST['data']);
|
||||
|
||||
$_POST = array('data' => array(
|
||||
'Article' => array('title' => 'some title'),
|
||||
'Tag' => array('Tag' => array(1, 2))
|
||||
));
|
||||
$request = new CakeRequest('some/path');
|
||||
$this->assertEquals($request->data, $_POST['data']);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue