Skip to content

Commit

Permalink
#3504 Tidy test only and final method
Browse files Browse the repository at this point in the history
  • Loading branch information
rbygrave committed Oct 24, 2024
1 parent d8f321d commit 32cd081
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public void appendSelect(DbSqlContext ctx, boolean subQuery) {
}

@Override
public void appendGroupBy(DbSqlContext ctx, boolean subQuery) {
public final void appendGroupBy(DbSqlContext ctx, boolean subQuery) {
ctx.appendParseSelect(parsedFormula, null);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -419,8 +419,10 @@ void dto_test_formula_with_group_by() {

List<DCustFormula> ret = query.asDto(DCustFormula.class).findList();

log.info(query.getGeneratedSql());
log.info(ret.toString());
String sql = query.getGeneratedSql();
assertThat(sql)
.describedAs("group by formula only")
.contains("from contact t0 group by concat(first_name, last_name) order by custname desc");
assertThat(ret.get(0).getCustname()).isEqualTo("TracyRed");
assertThat(ret.get(0).getCnt()).isEqualTo(1L);
}
Expand Down

0 comments on commit 32cd081

Please sign in to comment.