|
|
|
|
@ -36,6 +36,7 @@ import static org.assertj.core.api.Assertions.assertThat;
@@ -36,6 +36,7 @@ import static org.assertj.core.api.Assertions.assertThat;
|
|
|
|
|
* |
|
|
|
|
* @author Sam Brannen |
|
|
|
|
* @since 6.1 |
|
|
|
|
* @see SimpleJdbcInsertTests |
|
|
|
|
*/ |
|
|
|
|
class SimpleJdbcInsertIntegrationTests { |
|
|
|
|
|
|
|
|
|
@ -90,7 +91,9 @@ class SimpleJdbcInsertIntegrationTests {
@@ -90,7 +91,9 @@ class SimpleJdbcInsertIntegrationTests {
|
|
|
|
|
|
|
|
|
|
insert.compile(); |
|
|
|
|
// NOTE: quoted identifiers in H2/HSQL will be UPPERCASE!
|
|
|
|
|
assertThat(insert.getInsertString()).isEqualTo("INSERT INTO \"USERS\" (\"FIRST_NAME\", \"LAST_NAME\") VALUES(?, ?)"); |
|
|
|
|
assertThat(insert.getInsertString()).isEqualToIgnoringNewLines(""" |
|
|
|
|
INSERT INTO "USERS" ("FIRST_NAME", "LAST_NAME") VALUES(?, ?) |
|
|
|
|
"""); |
|
|
|
|
|
|
|
|
|
insertJaneSmith(insert); |
|
|
|
|
} |
|
|
|
|
@ -133,7 +136,9 @@ class SimpleJdbcInsertIntegrationTests {
@@ -133,7 +136,9 @@ class SimpleJdbcInsertIntegrationTests {
|
|
|
|
|
|
|
|
|
|
insert.compile(); |
|
|
|
|
// NOTE: quoted identifiers in H2/HSQL will be UPPERCASE!
|
|
|
|
|
assertThat(insert.getInsertString()).isEqualTo("INSERT INTO \"MY_SCHEMA\".\"USERS\" (\"FIRST_NAME\", \"LAST_NAME\") VALUES(?, ?)"); |
|
|
|
|
assertThat(insert.getInsertString()).isEqualToIgnoringNewLines(""" |
|
|
|
|
INSERT INTO "MY_SCHEMA"."USERS" ("FIRST_NAME", "LAST_NAME") VALUES(?, ?) |
|
|
|
|
"""); |
|
|
|
|
|
|
|
|
|
insertJaneSmith(insert); |
|
|
|
|
} |
|
|
|
|
|