File tree Expand file tree Collapse file tree 2 files changed +5
-9
lines changed
module/spring-boot-batch-jdbc
src/test/java/org/springframework/boot/batch/jdbc/autoconfigure Expand file tree Collapse file tree 2 files changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -42,10 +42,9 @@ dependencies {
4242 testImplementation(" io.micrometer:micrometer-observation-test" )
4343
4444 testRuntimeOnly(" ch.qos.logback:logback-classic" )
45- testRuntimeOnly(" com.fasterxml.jackson.core:jackson-databind" )
46- testRuntimeOnly(" com.fasterxml.jackson.datatype:jackson-datatype-jsr310" )
4745 testRuntimeOnly(" com.h2database:h2" )
4846 testRuntimeOnly(" com.zaxxer:HikariCP" )
47+ testRuntimeOnly(" tools.jackson.core:jackson-databind" )
4948}
5049
5150tasks. named(" compileTestJava" ) {
Original file line number Diff line number Diff line change 4343import org .springframework .batch .core .repository .ExecutionContextSerializer ;
4444import org .springframework .batch .core .repository .JobRepository ;
4545import org .springframework .batch .core .repository .dao .DefaultExecutionContextSerializer ;
46+ import org .springframework .batch .core .repository .dao .JacksonExecutionContextStringSerializer ;
4647import org .springframework .batch .core .step .Step ;
4748import org .springframework .beans .factory .annotation .Autowired ;
4849import org .springframework .beans .factory .config .ConfigurableListableBeanFactory ;
@@ -480,17 +481,13 @@ void whenTheUserDefinesAJobNameThatDoesNotExistWithRegisteredJobFailsFast() {
480481 }
481482
482483 @ Test
483- @ SuppressWarnings ("removal" )
484484 void customExecutionContextSerializerIsUsed () {
485485 this .contextRunner .withUserConfiguration (EmbeddedDataSourceConfiguration .class )
486- .withBean (ExecutionContextSerializer .class ,
487- org .springframework .batch .core .repository .dao .Jackson2ExecutionContextStringSerializer ::new )
486+ .withBean (ExecutionContextSerializer .class , JacksonExecutionContextStringSerializer ::new )
488487 .run ((context ) -> {
489- assertThat (context ).hasSingleBean (
490- org .springframework .batch .core .repository .dao .Jackson2ExecutionContextStringSerializer .class );
488+ assertThat (context ).hasSingleBean (JacksonExecutionContextStringSerializer .class );
491489 assertThat (context .getBean (SpringBootBatchJdbcConfiguration .class ).getExecutionContextSerializer ())
492- .isInstanceOf (
493- org .springframework .batch .core .repository .dao .Jackson2ExecutionContextStringSerializer .class );
490+ .isInstanceOf (JacksonExecutionContextStringSerializer .class );
494491 });
495492 }
496493
You can’t perform that action at this time.
0 commit comments