mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
Added test for ticket #2321
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@4721 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
f8995e0bde
commit
4da63e762f
1 changed files with 4 additions and 0 deletions
|
@ -862,6 +862,10 @@ class DboSourceTest extends UnitTestCase {
|
||||||
$result = $this->db->conditions("lower(Article.title) LIKE 'a%'");
|
$result = $this->db->conditions("lower(Article.title) LIKE 'a%'");
|
||||||
$expected = " WHERE lower( `Article`.`title`) LIKE 'a%'";
|
$expected = " WHERE lower( `Article`.`title`) LIKE 'a%'";
|
||||||
$this->assertEqual($result, $expected);
|
$this->assertEqual($result, $expected);
|
||||||
|
|
||||||
|
$result = $this->db->conditions('((MATCH(Video.title) AGAINST(\'My Search*\' IN BOOLEAN MODE) * 2) + (MATCH( Video.description) AGAINST(\'My Search*\' IN BOOLEAN MODE) * 0.4) + (MATCH(Video.tags) AGAINST(\'My Search*\' IN BOOLEAN MODE) * 1.5))');
|
||||||
|
$expected = ' WHERE ((MATCH( `Video`.`title`) AGAINST(\'My Search*\' IN BOOLEAN MODE) * 2) + (MATCH( `Video`.`description`) AGAINST(\'My Search*\' IN BOOLEAN MODE) * 0.4) + (MATCH( `Video`.`tags`) AGAINST(\'My Search*\' IN BOOLEAN MODE) * 1.5))';
|
||||||
|
$this->assertEqual($result, $expected);
|
||||||
}
|
}
|
||||||
|
|
||||||
function testArrayConditionsParsing() {
|
function testArrayConditionsParsing() {
|
||||||
|
|
Loading…
Reference in a new issue