File tree 3 files changed +51
-0
lines changed
jackson2.14.2Test/kotlin/io/temporal/common/converter
jackson2.9.0Test/kotlin/io/temporal/common/converter
3 files changed +51
-0
lines changed Original file line number Diff line number Diff line change 1
1
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
2
+ import org.gradle.api.plugins.jvm.JvmTestSuite
2
3
3
4
plugins {
4
5
id ' org.jlleitschuh.gradle.ktlint' version ' 11.3.1'
@@ -43,3 +44,27 @@ task registerNamespace(type: JavaExec) {
43
44
44
45
test. dependsOn ' registerNamespace'
45
46
47
+ def jacksonVersions = [' 2.9.0' , " $jacksonVersion " . toString()]
48
+
49
+ testing {
50
+ suites {
51
+ jacksonVersions. forEach { jacksonVersion ->
52
+ " jackson${ jacksonVersion} Test" (JvmTestSuite ) {
53
+ useJUnit(junitVersion)
54
+ dependencies {
55
+ implementation project()
56
+ implementation " com.fasterxml.jackson.datatype:jackson-datatype-jsr310:$jacksonVersion !!"
57
+ implementation " com.fasterxml.jackson.datatype:jackson-datatype-jdk8:$jacksonVersion !!"
58
+ implementation(" com.fasterxml.jackson.module:jackson-module-kotlin:$jacksonVersion !!" ) {
59
+ exclude group : ' org.jetbrains.kotlin' , module : ' kotlin-reflect'
60
+ }
61
+
62
+ implementation project(' :temporal-testing' )
63
+ implementation " junit:junit:${ junitVersion} "
64
+ }
65
+ }
66
+ }
67
+ }
68
+ }
69
+
70
+ test. dependsOn(" jackson2.9.0Test" , " jackson2.14.2Test" )
Original file line number Diff line number Diff line change
1
+ package io.temporal.common.converter
2
+
3
+ import com.fasterxml.jackson.module.kotlin.PackageVersion
4
+ import org.junit.Assert.assertEquals
5
+ import org.junit.Test
6
+
7
+ class KotlinObjectMapperFactoryTest {
8
+ @Test
9
+ fun `test jackson 2 14 2` () {
10
+ assertEquals(PackageVersion .VERSION .toString(), " 2.14.2" )
11
+ KotlinObjectMapperFactory .new()
12
+ }
13
+ }
Original file line number Diff line number Diff line change
1
+ package io.temporal.common.converter
2
+
3
+ import com.fasterxml.jackson.module.kotlin.PackageVersion
4
+ import org.junit.Assert.assertEquals
5
+ import org.junit.Test
6
+
7
+ class KotlinObjectMapperFactoryTest {
8
+ @Test
9
+ fun `test jackson 2 9 0` () {
10
+ assertEquals(PackageVersion .VERSION .toString(), " 2.9.0" )
11
+ KotlinObjectMapperFactory .new()
12
+ }
13
+ }
You can’t perform that action at this time.
0 commit comments