Merge branch '2.5.x'
Closes gh-27186
This commit is contained in:
@@ -101,7 +101,9 @@ public enum EmbeddedDatabaseConnection {
|
||||
OptionsCapableConnectionFactory optionsCapable = OptionsCapableConnectionFactory.unwrapFrom(connectionFactory);
|
||||
if (optionsCapable == null) {
|
||||
throw new IllegalArgumentException(
|
||||
"Cannot determine database's type as ConnectionFactory is not options-capable");
|
||||
"Cannot determine database's type as ConnectionFactory is not options-capable. To be "
|
||||
+ "options-capable, a ConnectionFactory should be created with "
|
||||
+ ConnectionFactoryBuilder.class.getName());
|
||||
}
|
||||
ConnectionFactoryOptions options = optionsCapable.getOptions();
|
||||
for (EmbeddedDatabaseConnection candidate : values()) {
|
||||
|
||||
@@ -89,7 +89,9 @@ class EmbeddedDatabaseConnectionTests {
|
||||
assertThatIllegalArgumentException()
|
||||
.isThrownBy(() -> EmbeddedDatabaseConnection
|
||||
.isEmbedded(ConnectionFactories.get("r2dbc:pool:h2:mem:///" + UUID.randomUUID())))
|
||||
.withMessage("Cannot determine database's type as ConnectionFactory is not options-capable");
|
||||
.withMessage("Cannot determine database's type as ConnectionFactory is not options-capable. To be "
|
||||
+ "options-capable, a ConnectionFactory should be created with "
|
||||
+ "org.springframework.boot.r2dbc.ConnectionFactoryBuilder");
|
||||
}
|
||||
|
||||
static Stream<Arguments> urlParameters() {
|
||||
|
||||
Reference in New Issue
Block a user