Skip to content

Commit 11a2b07

Browse files
vbabaninstIncMale
andauthored
Update src/integrationTest/java/com/mongodb/hibernate/jdbc/MongoPreparedStatementIntegrationTests.java
Co-authored-by: Valentin Kovalenko <[email protected]>
1 parent 39df511 commit 11a2b07

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/integrationTest/java/com/mongodb/hibernate/jdbc/MongoPreparedStatementIntegrationTests.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -698,10 +698,9 @@ void testNotSupportedUpdateElements(String unsupportedElement) {
698698
]
699699
}""",
700700
unsupportedElement))) {
701-
SQLFeatureNotSupportedException exception =
702-
assertThrows(SQLFeatureNotSupportedException.class, pstm::executeUpdate);
703-
assertThat(exception.getMessage())
704-
.isEqualTo(format("Unsupported elements in update command: [%s]", unsupportedElement));
701+
assertThatThrownBy(pstm::executeUpdate)
702+
.isInstanceOf(SQLFeatureNotSupportedException.class)
703+
.hasMessage("Unsupported elements in update command: [%s]".formatted(unsupportedElement));
705704
}
706705
});
707706
}

0 commit comments

Comments
 (0)