No effective change - add test for selecting only some @Aggregation properties

This commit is contained in:
Rob Bygrave
2018-03-05 19:59:40 +13:00
parent 62cdfb3209
commit 5a3e386b7c
@@ -111,6 +111,18 @@ public class TestAggregationCount extends BaseTestCase {
assertThat(sql).contains(" order by sum(u1.units), t0.name");
}
@Test
public void testSelectSome() {
Query<TEventOne> query0 = Ebean.find(TEventOne.class)
.select("name, count, totalUnits");
query0.findList();
String sql = sqlOf(query0, 5);
assertThat(sql).contains("select t0.id, t0.name, count(u1.id), sum(u1.units) from tevent_one t0");
assertThat(sql).contains("group by t0.id, t0.name");
}
@Test
public void testSelectOnly() {