Skip to content
This repository
Browse code

Fix failing tests caused by previous commit.

  • Loading branch information...
commit 6d6ac1083425ecc4e0efe4be6ce98d8cea6a2989 1 parent 58a2ee0
Mark Story authored November 20, 2011
2  lib/Cake/Console/Command/Task/FixtureTask.php
@@ -279,7 +279,7 @@ public function getPath() {
279 279
  */
280 280
 	protected function _generateSchema($tableInfo) {
281 281
 		$schema = $this->_Schema->generateTable('f', $tableInfo);
282  
-		return substr($schema, 10, -2);
  282
+		return substr($schema, 13, -2);
283 283
 	}
284 284
 
285 285
 /**
12  lib/Cake/Test/Case/Console/Command/SchemaShellTest.php
@@ -353,12 +353,12 @@ public function testGenerateWithPlugins() {
353 353
 		$contents = $this->file->read();
354 354
 
355 355
 		$this->assertRegExp('/class TestPluginSchema/', $contents);
356  
-		$this->assertRegExp('/var \$posts/', $contents);
357  
-		$this->assertRegExp('/var \$auth_users/', $contents);
358  
-		$this->assertRegExp('/var \$authors/', $contents);
359  
-		$this->assertRegExp('/var \$test_plugin_comments/', $contents);
360  
-		$this->assertNotRegExp('/var \$users/', $contents);
361  
-		$this->assertNotRegExp('/var \$articles/', $contents);
  356
+		$this->assertRegExp('/public \$posts/', $contents);
  357
+		$this->assertRegExp('/public \$auth_users/', $contents);
  358
+		$this->assertRegExp('/public \$authors/', $contents);
  359
+		$this->assertRegExp('/public \$test_plugin_comments/', $contents);
  360
+		$this->assertNotRegExp('/public \$users/', $contents);
  361
+		$this->assertNotRegExp('/public \$articles/', $contents);
362 362
 		CakePlugin::unload();
363 363
 	}
364 364
 
1  lib/Cake/Test/Case/Console/Command/Task/FixtureTaskTest.php
@@ -21,6 +21,7 @@
21 21
 App::uses('Shell', 'Console');
22 22
 App::uses('ConsoleOutput', 'Console');
23 23
 App::uses('ConsoleInput', 'Console');
  24
+App::uses('ModelTask', 'Console/Command/Task');
24 25
 App::uses('FixtureTask', 'Console/Command/Task');
25 26
 App::uses('TemplateTask', 'Console/Command/Task');
26 27
 App::uses('DbConfigTask', 'Console/Command/Task');
2  lib/Cake/Test/Case/Model/CakeSchemaTest.php
@@ -741,7 +741,7 @@ public function testGenerateTable() {
741 741
 			'indexes' => array('PRIMARY' => array('column' => 'id', 'unique' => true)),
742 742
 		);
743 743
 		$result = $this->Schema->generateTable('posts', $posts);
744  
-		$this->assertRegExp('/var \$posts/', $result);
  744
+		$this->assertRegExp('/public \$posts/', $result);
745 745
 	}
746 746
 /**
747 747
  * testSchemaWrite method

0 notes on commit 6d6ac10

Please sign in to comment.
Something went wrong with that request. Please try again.