Skip to content

Commit adf5b41

Browse files
Enable SQL logging and verify entity graph is applied
1 parent cd5e4f4 commit adf5b41

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

data-jpa/src/aotSmokeTest/java/com/example/data/jpa/DataJpaApplicationAotTests.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,10 @@ void callback(AssertableOutput output) {
7373
@Test
7474
void entityGraph(AssertableOutput output) {
7575
Awaitility.await().atMost(Duration.ofSeconds(10)).untilAsserted(() -> {
76-
assertThat(output).hasSingleLineContaining(
77-
"namedEntityGraph: Book{title='Spring in Action', authors=[Author{name='Craig Walls'}]}");
76+
assertThat(output)
77+
.hasLineContaining("left join (book_authors a1_0 join author a1_1 on a1_1.id=a1_0.authors_id)")
78+
.hasSingleLineContaining(
79+
"namedEntityGraph: Book{title='Spring in Action', authors=[Author{name='Craig Walls'}]}");
7880
});
7981
}
8082

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
logging.level.org.hibernate.SQL=debug

0 commit comments

Comments
 (0)