Making code PHP4 friendly again

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@7460 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
mariano.iglesias 2008-08-13 11:29:33 +00:00
parent fb15d71284
commit 0b5fbe04f6

View file

@ -156,7 +156,7 @@ class CakeTestCase extends UnitTestCase {
if (!isset($this->db)) { if (!isset($this->db)) {
$this->_initDb(); $this->_initDb();
} }
$classRegistry = ClassRegistry::getInstance(); $classRegistry =& ClassRegistry::getInstance();
if ($controller->uses === false) { if ($controller->uses === false) {
$list = array($controller->modelClass); $list = array($controller->modelClass);
@ -169,8 +169,8 @@ class CakeTestCase extends UnitTestCase {
foreach ($list as $name) { foreach ($list as $name) {
if ((is_array($params['fixturize']) && in_array($name, $params['fixturize'])) || $params['fixturize'] === true) { if ((is_array($params['fixturize']) && in_array($name, $params['fixturize'])) || $params['fixturize'] === true) {
if (class_exists($name) || App::import('Model', $name)) { if (class_exists($name) || App::import('Model', $name)) {
$object =& ClassRegistry::init($name); $object =& ClassRegistry::init($name);
$db =& ConnectionManager::getDataSource($object->useDbConfig); $db =& ConnectionManager::getDataSource($object->useDbConfig);
$db->cacheSources = false; $db->cacheSources = false;
@ -728,4 +728,4 @@ class CakeTestCase extends UnitTestCase {
} }
} }
} }
?> ?>