Browse Source

Skip testSchemaReadWithConfigPrefix test if an existing prefix has already been set

Kyle Robinson Young 14 years ago
parent
commit
42583ff6a5
1 changed files with 3 additions and 0 deletions
  1. 3 0
      lib/Cake/Test/Case/Model/CakeSchemaTest.php

+ 3 - 0
lib/Cake/Test/Case/Model/CakeSchemaTest.php

@@ -640,8 +640,11 @@ class CakeSchemaTest extends CakeTestCase {
  */
 	public function testSchemaReadWithConfigPrefix() {
 		$this->skipIf($this->db instanceof Sqlite, 'Cannot open 2 connections to Sqlite');
+		
 		$db = ConnectionManager::getDataSource('test');
 		$config = $db->config;
+		$this->skipIf(!empty($config['prefix']), 'This test can not be executed with datasource prefix set.');
+		
 		$config['prefix'] = 'schema_test_prefix_';
 		ConnectionManager::create('schema_prefix', $config);
 		$read = $this->Schema->read(array('connection' => 'schema_prefix', 'models' => false));