Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Tidy up variable names.

Variables with _ in them are confusing, try to use clearer names.
  • Loading branch information...
commit 9cdc3927f2874af6be9e6de60e23e5d8871de02e 1 parent 631082a
@markstory markstory authored
Showing with 7 additions and 7 deletions.
  1. +7 −7 lib/Cake/TestSuite/ControllerTestCase.php
View
14 lib/Cake/TestSuite/ControllerTestCase.php
@@ -329,11 +329,11 @@ public function generate($controller, $mocks = array()) {
), (array)$mocks);
list($plugin, $name) = pluginSplit($controller);
- $_controller = $this->getMock($name . 'Controller', $mocks['methods'], array(), '', false);
- $_controller->name = $name;
+ $controllerObj = $this->getMock($name . 'Controller', $mocks['methods'], array(), '', false);
+ $controllerObj->name = $name;
$request = $this->getMock('CakeRequest');
$response = $this->getMock('CakeResponse', array('_sendHeader'));
- $_controller->__construct($request, $response);
+ $controllerObj->__construct($request, $response);
$config = ClassRegistry::config('Model');
foreach ($mocks['models'] as $model => $methods) {
@@ -363,14 +363,14 @@ public function generate($controller, $mocks = array()) {
'class' => $componentClass
));
}
- $_component = $this->getMock($componentClass, $methods, array(), '', false);
- $_controller->Components->set($name, $_component);
+ $componentObj = $this->getMock($componentClass, $methods, array(), '', false);
+ $controllerObj->Components->set($name, $componentObj);
}
- $_controller->constructClasses();
+ $controllerObj->constructClasses();
$this->_dirtyController = false;
- $this->controller = $_controller;
+ $this->controller = $controllerObj;
return $this->controller;
}
Please sign in to comment.
Something went wrong with that request. Please try again.