Fixing options[data] always writing its data into $_POST['data'].

It now just overwrites $_POST.
Fixes #1917
This commit is contained in:
Mark Story 2011-08-20 09:46:01 -04:00
parent 0091fac5b9
commit 70f47378f9
2 changed files with 2 additions and 7 deletions

View file

@ -98,11 +98,6 @@ class ControllerTestCaseTestController extends AppController {
}
/**
* Used to get a testable concrete class of the test subject
*/
class TestingControllerTestCase extends ControllerTestCase {}
/**
* ControllerTestCaseTest
*
@ -132,7 +127,7 @@ class ControllerTestCaseTest extends CakeTestCase {
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View' . DS)
));
CakePlugin::loadAll();
$this->Case = new TestingControllerTestCase();
$this->Case = $this->getMockForAbstractClass('ControllerTestCase');
Router::reload();
}

View file

@ -194,7 +194,7 @@ abstract class ControllerTestCase extends CakeTestCase {
$_GET = $options['data'];
$_POST = array();
} else {
$_POST = array('data' => $options['data']);
$_POST = $options['data'];
$_GET = array();
}
$request = new CakeRequest($url);