Add missing hint for converting String to URI

Closes gh-30627
This commit is contained in:
Sébastien Deleuze
2023-06-09 14:11:46 +02:00
parent 071d6a2a5a
commit 9b4e0e9837
2 changed files with 12 additions and 2 deletions

View File

@@ -16,6 +16,7 @@
package org.springframework.aot.hint.support;
import java.net.URI;
import java.time.LocalDate;
import org.junit.jupiter.api.BeforeEach;
@@ -52,4 +53,9 @@ class ObjectToObjectConverterRuntimeHintsTests {
assertThat(RuntimeHintsPredicates.reflection().onMethod(java.sql.Date.class.getMethod("valueOf", LocalDate.class))).accepts(this.hints);
}
@Test
void uriHasHints() throws NoSuchMethodException {
assertThat(RuntimeHintsPredicates.reflection().onConstructor(URI.class.getConstructor(String.class))).accepts(this.hints);
}
}