|
|
@@ -1960,7 +1960,7 @@ class MysqlTest extends CakeTestCase {
|
|
|
$this->assertEquals($expected, $result);
|
|
|
|
|
|
$result = $this->Dbo->conditions(array('score' => array(2 => 1, 2, 10)));
|
|
|
- $expected = " WHERE score IN (1, 2, 10)";
|
|
|
+ $expected = " WHERE `score` IN (1, 2, 10)";
|
|
|
$this->assertEquals($expected, $result);
|
|
|
|
|
|
$result = $this->Dbo->conditions("Aro.rght = Aro.lft + 1.1");
|
|
|
@@ -2240,7 +2240,7 @@ class MysqlTest extends CakeTestCase {
|
|
|
$this->assertEquals($expected, $result);
|
|
|
|
|
|
$result = $this->Dbo->conditions(array('score' => array(1, 2, 10)));
|
|
|
- $expected = " WHERE score IN (1, 2, 10)";
|
|
|
+ $expected = " WHERE `score` IN (1, 2, 10)";
|
|
|
$this->assertEquals($expected, $result);
|
|
|
|
|
|
$result = $this->Dbo->conditions(array('score' => array()));
|
|
|
@@ -2331,7 +2331,7 @@ class MysqlTest extends CakeTestCase {
|
|
|
'NOT' => array('Course.id' => null, 'Course.vet' => 'N', 'level_of_education_id' => array(912,999)),
|
|
|
'Enrollment.yearcompleted >' => '0')
|
|
|
);
|
|
|
- $this->assertRegExp('/^\s*WHERE\s+\(NOT\s+\(`Course`\.`id` IS NULL\)\s+AND NOT\s+\(`Course`\.`vet`\s+=\s+\'N\'\)\s+AND NOT\s+\(level_of_education_id IN \(912, 999\)\)\)\s+AND\s+`Enrollment`\.`yearcompleted`\s+>\s+\'0\'\s*$/', $result);
|
|
|
+ $this->assertRegExp('/^\s*WHERE\s+\(NOT\s+\(`Course`\.`id` IS NULL\)\s+AND NOT\s+\(`Course`\.`vet`\s+=\s+\'N\'\)\s+AND NOT\s+\(`level_of_education_id` IN \(912, 999\)\)\)\s+AND\s+`Enrollment`\.`yearcompleted`\s+>\s+\'0\'\s*$/', $result);
|
|
|
|
|
|
$result = $this->Dbo->conditions(array('id <>' => '8'));
|
|
|
$this->assertRegExp('/^\s*WHERE\s+`id`\s+<>\s+\'8\'\s*$/', $result);
|
|
|
@@ -2367,7 +2367,7 @@ class MysqlTest extends CakeTestCase {
|
|
|
|
|
|
$conditions = array('id' => array(2, 5, 6, 9, 12, 45, 78, 43, 76));
|
|
|
$result = $this->Dbo->conditions($conditions);
|
|
|
- $expected = " WHERE id IN (2, 5, 6, 9, 12, 45, 78, 43, 76)";
|
|
|
+ $expected = " WHERE `id` IN (2, 5, 6, 9, 12, 45, 78, 43, 76)";
|
|
|
$this->assertEquals($expected, $result);
|
|
|
|
|
|
$conditions = array('title' => 'user(s)');
|