This commit is contained in:
parent
8a0898d3ed
commit
57a6200b5e
1 changed files with 11 additions and 0 deletions
|
@ -174,7 +174,18 @@ class Doctrine_Search_Query_TestCase extends Doctrine_UnitTestCase
|
||||||
|
|
||||||
$this->assertEqual($ret, $sql);
|
$this->assertEqual($ret, $sql);
|
||||||
}
|
}
|
||||||
|
public function testParseClauseSupportsMixingOfOperatorsAndDeeplyNestedParenthesis2()
|
||||||
|
{
|
||||||
|
$q = new Doctrine_Search_Query('SearchTestIndex');
|
||||||
|
$ret = $q->parseClause('rdbms (((doctrine OR orm) AND dbal) OR database)');
|
||||||
|
|
||||||
|
$sql = '(search_test_id IN (SELECT search_test_id FROM search_test_index WHERE keyword = ?)) AND '
|
||||||
|
. '((search_test_id IN (SELECT search_test_id FROM search_test_index WHERE keyword = ? OR keyword = ?)) '
|
||||||
|
. 'AND (search_test_id IN (SELECT search_test_id FROM search_test_index WHERE keyword = ?))'
|
||||||
|
. ' OR keyword = ?)';
|
||||||
|
|
||||||
|
$this->assertEqual($ret, $sql);
|
||||||
|
}
|
||||||
/**
|
/**
|
||||||
public function testSearchSupportsAndOperator()
|
public function testSearchSupportsAndOperator()
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Reference in a new issue