|
@@ -733,12 +733,12 @@ abstract class TestCase extends BaseTestCase
|
|
|
* Mock a model, maintain fixtures and table association
|
|
* Mock a model, maintain fixtures and table association
|
|
|
*
|
|
*
|
|
|
* @param string $alias The model to get a mock for.
|
|
* @param string $alias The model to get a mock for.
|
|
|
- * @param array $methods The list of methods to mock
|
|
|
|
|
|
|
+ * @param array|null $methods The list of methods to mock
|
|
|
* @param array $options The config data for the mock's constructor.
|
|
* @param array $options The config data for the mock's constructor.
|
|
|
* @throws \Cake\ORM\Exception\MissingTableClassException
|
|
* @throws \Cake\ORM\Exception\MissingTableClassException
|
|
|
* @return \Cake\ORM\Table|\PHPUnit_Framework_MockObject_MockObject
|
|
* @return \Cake\ORM\Table|\PHPUnit_Framework_MockObject_MockObject
|
|
|
*/
|
|
*/
|
|
|
- public function getMockForModel($alias, array $methods = [], array $options = [])
|
|
|
|
|
|
|
+ public function getMockForModel($alias, $methods = [], array $options = [])
|
|
|
{
|
|
{
|
|
|
/** @var \Cake\ORM\Table $className */
|
|
/** @var \Cake\ORM\Table $className */
|
|
|
$className = $this->_getTableClassName($alias, $options);
|
|
$className = $this->_getTableClassName($alias, $options);
|