Browse Source

Upgrade to Kotlin 1.7.20

This commit also temporarily changes a test assertion for the Jackson
Kotlin module.
As of https://youtrack.jetbrains.com/issue/KT-52932, Kotlin enhanced the
`IntRange` and this change is not supported yet by the Jackson Kotlin
module. An issue has been reported here:
FasterXML/jackson-module-kotlin#582

Closes gh-29225
pull/29228/head
Brian Clozel 3 years ago
parent
commit
d98e27cf79
  1. 4
      build.gradle
  2. 3
      spring-web/src/test/java/org/springframework/http/converter/json/Jackson2ObjectMapperBuilderTests.java

4
build.gradle

@ -2,8 +2,8 @@ plugins { @@ -2,8 +2,8 @@ plugins {
id 'io.spring.nohttp' version '0.0.10'
id 'io.freefair.aspectj' version '6.5.0.3' apply false
id 'org.jetbrains.dokka' version '1.7.10' apply false
id 'org.jetbrains.kotlin.jvm' version '1.7.10' apply false
id 'org.jetbrains.kotlin.plugin.serialization' version '1.7.10' apply false
id 'org.jetbrains.kotlin.jvm' version '1.7.20' apply false
id 'org.jetbrains.kotlin.plugin.serialization' version '1.7.20' apply false
id 'org.asciidoctor.jvm.convert' version '3.3.2'
id 'org.asciidoctor.jvm.pdf' version '3.3.2'
id 'org.unbroken-dome.xjc' version '2.0.0' apply false

3
spring-web/src/test/java/org/springframework/http/converter/json/Jackson2ObjectMapperBuilderTests.java

@ -289,7 +289,8 @@ class Jackson2ObjectMapperBuilderTests { @@ -289,7 +289,8 @@ class Jackson2ObjectMapperBuilderTests {
// Kotlin module
IntRange range = new IntRange(1, 3);
assertThat(new String(objectMapper.writeValueAsBytes(range), "UTF-8")).isEqualTo("{\"start\":1,\"end\":3}");
// temporarily change the assertion, see https://github.com/FasterXML/jackson-module-kotlin/issues/582
assertThat(new String(objectMapper.writeValueAsBytes(range), "UTF-8")).isEqualTo("{\"start\":1,\"end\":3,\"endExclusive\":4}");
}
@Test // gh-22576

Loading…
Cancel
Save