diff --git a/tests/Query/GroupbyTestCase.php b/tests/Query/GroupbyTestCase.php new file mode 100644 index 000000000..8976339cf --- /dev/null +++ b/tests/Query/GroupbyTestCase.php @@ -0,0 +1,43 @@ +. + */ + +/** + * Doctrine_Query_Groupby_TestCase + * + * @package Doctrine + * @license http://www.opensource.org/licenses/lgpl-license.php LGPL + * @author Konsta Vesterinen + * @version $Revision$ + * @category Object Relational Mapping + * @link www.phpdoctrine.com + * @since 1.0 + */ +class Doctrine_Query_Groupby_TestCase extends Doctrine_UnitTestCase +{ + public function testAggregateFunctionsInHavingReturnValidSql() + { + $q = new Doctrine_Query(); + + $q->parseQuery('SELECT u.name, COUNT(p.id) count FROM User u LEFT JOIN u.Phonenumber p GROUP BY count'); + + $this->assertEqual($q->getQuery(), ''); + } +}