Skip to content

Commit

Permalink
#2317 - Plus test changes due to tidy whitespace on sql generation
Browse files Browse the repository at this point in the history
  • Loading branch information
rbygrave committed Aug 16, 2021
1 parent 12220d4 commit 4163b4d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ private void insertUpdateBridgeD(BUser user, BSite site) {
sql = LoggedSqlCollector.stop();

assertThat(sql).hasSize(2);
assertSql(sql.get(0)).contains("select t0.site_id, t0.user_id, t0.site_id, t0.user_id, t0.access_level, t0.version from bsite_user_d t0 where t0.site_id = ? and t0.user_id = ?");
assertSql(sql.get(0)).contains("select t0.site_id, t0.user_id, t0.site_id, t0.user_id, t0.access_level, t0.version from bsite_user_d t0 where t0.site_id=? and t0.user_id=?");
assertSql(sql.get(1)).contains("update bsite_user_d set access_level=?, version=? where site_id=? and user_id=? and version=?");
}

Expand Down Expand Up @@ -178,7 +178,7 @@ private void insertUpdateBridgeE(BUser user, BSite site) {
sql = LoggedSqlCollector.stop();

assertThat(sql).hasSize(2);
assertSql(sql.get(0)).contains("select t0.site_id, t0.user_id, t0.access_level, t0.site_id, t0.user_id from bsite_user_e t0 where t0.site_id = ? and t0.user_id = ?");
assertSql(sql.get(0)).contains("select t0.site_id, t0.user_id, t0.access_level, t0.site_id, t0.user_id from bsite_user_e t0 where t0.site_id=? and t0.user_id=?");
assertSql(sql.get(1)).contains("update bsite_user_e set access_level=? where site_id=? and user_id=?");

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public void findVersions_when_embeddedId() throws InterruptedException {
assertThat(namePair.getOldValue()).isEqualTo("ten");

assertThat(sql).hasSize(1);
assertThat(sql.get(0)).contains("from hembi_bean_with_history t0 where t0.part = ? and t0.brand = ?");
assertThat(sql.get(0)).contains("from hembi_bean_with_history t0 where t0.part=? and t0.brand=?");
if (isH2()) {
assertThat(sql.get(0)).contains("order by t0.sys_period_start desc");
} else if (isPostgres()) {
Expand Down

0 comments on commit 4163b4d

Please sign in to comment.