1
0
mirror of synced 2025-02-02 13:31:45 +03:00

#1188 - minor CS fixes (avoiding DQL one-liner)

This commit is contained in:
Marco Pivetta 2014-11-27 17:54:02 +01:00
parent 684ae859ce
commit 2f57c4fef9

View File

@ -156,7 +156,9 @@ class PaginationTest extends \Doctrine\Tests\OrmFunctionalTestCase
{ {
/** @var $query Query */ /** @var $query Query */
$query = $this->_em->createQuery( $query = $this->_em->createQuery(
'SELECT u, (CASE WHEN u.id < :vipMaxId THEN 1 ELSE 0 END) AS hidden promotedFirst FROM Doctrine\Tests\Models\CMS\CmsUser u WHERE u.id < :id or 1=1 ORDER BY promotedFirst' 'SELECT u, (CASE WHEN u.id < :vipMaxId THEN 1 ELSE 0 END) AS hidden promotedFirst
FROM Doctrine\\Tests\\Models\\CMS\\CmsUser u
WHERE u.id < :id or 1=1'
); );
$query->setParameter('vipMaxId', 10); $query->setParameter('vipMaxId', 10);
$query->setParameter('id', 100); $query->setParameter('id', 100);
@ -164,7 +166,6 @@ class PaginationTest extends \Doctrine\Tests\OrmFunctionalTestCase
$paginator = new Paginator($query); $paginator = new Paginator($query);
//
$getCountQuery = new ReflectionMethod($paginator, 'getCountQuery'); $getCountQuery = new ReflectionMethod($paginator, 'getCountQuery');
$getCountQuery->setAccessible(true); $getCountQuery->setAccessible(true);