Browse Source

php5 corrections

euromark 14 years ago
parent
commit
973dce916a

+ 2 - 2
lib/Cake/Test/Case/Cache/Engine/MemcacheEngineTest.php

@@ -170,7 +170,7 @@ class MemcacheEngineTest extends CakeTestCase {
  * @return void
  */
 	public function testParseServerStringUnix() {
-		$Memcache =& new TestMemcacheEngine();
+		$Memcache = new TestMemcacheEngine();
 		$result = $Memcache->parseServerString('unix:///path/to/memcached.sock');
 		$this->assertEquals($result, array('unix:///path/to/memcached.sock', 0));
 	}
@@ -385,7 +385,7 @@ class MemcacheEngineTest extends CakeTestCase {
  * @return void
  */
 	public function testLongDurationEqualToZero() {
-		$memcache =& new TestMemcacheEngine();
+		$memcache = new TestMemcacheEngine();
 		$memcache->settings['compress'] = false;
 
 		$mock = $this->getMock('Memcache');

+ 1 - 1
lib/Cake/Test/Case/Controller/Component/PaginatorComponentTest.php

@@ -862,7 +862,7 @@ class PaginatorComponentTest extends CakeTestCase {
  * @return void
  */
 	public function testPaginateOrderVirtualFieldSharedWithRealField() {
-		$Controller =& new Controller($this->request);
+		$Controller = new Controller($this->request);
 		$Controller->uses = array('PaginatorControllerPost', 'PaginatorControllerComment');
 		$Controller->constructClasses();
 		$Controller->PaginatorControllerComment->virtualFields = array(

+ 1 - 1
lib/Cake/Test/Case/Model/Behavior/TranslateBehaviorTest.php

@@ -66,7 +66,7 @@ class TranslateBehaviorTest extends CakeTestCase {
 	public function testCountWithConditions() {
 		$this->loadFixtures('Translate', 'TranslatedItem');
 
-		$Model =& new TranslatedItem();
+		$Model = new TranslatedItem();
 		$Model->locale = 'eng';
 		$result = $Model->find('count', array(
 			'conditions' => array(

+ 1 - 1
lib/Cake/Test/Case/Model/ModelIntegrationTest.php

@@ -242,7 +242,7 @@ class ModelIntegrationTest extends BaseModelTest {
  */
 	public function testFindWithJoinsOption() {
 		$this->loadFixtures('Article', 'User');
-		$TestUser =& new User();
+		$TestUser = new User();
 
 		$options = array(
 			'fields' => array(

+ 1 - 1
lib/Cake/Test/Case/Utility/FileTest.php

@@ -434,7 +434,7 @@ class FileTest extends CakeTestCase {
 		if (!file_exists($tmpFile)) {
 			touch($tmpFile);
 		}
-		$File =& new File($tmpFile);
+		$File = new File($tmpFile);
 		$File->read();
 		$this->assertTrue($File->delete());
 	}