1616
1717package org .springframework .cloud .function .utils ;
1818
19- import java .lang .reflect .Field ;
2019import java .nio .charset .StandardCharsets ;
2120import java .time .ZonedDateTime ;
2221import java .util .Date ;
2322import java .util .List ;
2423import java .util .stream .Stream ;
2524
2625import com .google .gson .Gson ;
27- import org .junit .jupiter .api .Disabled ;
2826import org .junit .jupiter .api .Test ;
2927import org .junit .jupiter .params .ParameterizedTest ;
3028import org .junit .jupiter .params .provider .MethodSource ;
4139import org .springframework .context .ApplicationContext ;
4240import org .springframework .context .annotation .Configuration ;
4341import org .springframework .core .ResolvableType ;
44- import org .springframework .util .ReflectionUtils ;
45-
46-
4742
4843import static org .assertj .core .api .Assertions .assertThat ;
4944
@@ -82,7 +77,6 @@ public void objectNode_isJsonStringRepresentsCollection() {
8277
8378 // see https://github.com/spring-cloud/spring-cloud-function/issues/1189
8479 @ Test
85- @ Disabled ("https://github.com/spring-cloud/spring-cloud-function/issues/1304" )
8680 public void testJsonDateTimeConversion () {
8781 ApplicationContext context = SpringApplication .run (EmptyConfiguration .class );
8882 JsonMapper jsonMapper = context .getBean (JsonMapper .class );
@@ -91,16 +85,6 @@ public void testJsonDateTimeConversion() {
9185 assertThat (convertedJson ).contains ("\" zonedDateTime\" :\" 2024-10-16T16:13:29.964361+02:00\" " );
9286 }
9387
94- @ Test
95- public void testKotlinModuleRegistration () throws Exception {
96- ApplicationContext context = SpringApplication .run (EmptyConfiguration .class );
97- JsonMapper jsonMapper = context .getBean (JsonMapper .class );
98- Field mapperField = ReflectionUtils .findField (jsonMapper .getClass (), "mapper" );
99- mapperField .setAccessible (true );
100- ObjectMapper mapper = (ObjectMapper ) mapperField .get (jsonMapper );
101- //assertThat(mapper.getRegisteredModuleIds()).contains("com.fasterxml.jackson.module.kotlin.KotlinModule");
102- }
103-
10488 @ ParameterizedTest
10589 @ MethodSource ("params" )
10690 public void vanillaArray (JsonMapper mapper ) {
0 commit comments