File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed
src/main/kotlin/io/wwan13/implmockmvc/util Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ dependencies {
2
2
api(project(" :api" ))
3
3
4
4
implementation(" com.fasterxml.jackson.module:jackson-module-kotlin" )
5
+ implementation(" com.fasterxml.jackson.datatype:jackson-datatype-jsr310" )
5
6
6
7
implementation(" com.epages:restdocs-api-spec-mockmvc:0.16.0" )
7
8
}
Original file line number Diff line number Diff line change 1
1
package io.wwan13.implmockmvc.util
2
2
3
+ import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule
3
4
import com.fasterxml.jackson.module.kotlin.jacksonObjectMapper
4
5
5
6
object JsonSerializer {
6
7
7
- private val objectMapper = jacksonObjectMapper()
8
+ private val objectMapper = jacksonObjectMapper().registerModule( JavaTimeModule ())
8
9
9
10
fun serialize (value : Any ): String {
10
11
return objectMapper.writeValueAsString(value)
You can’t perform that action at this time.
0 commit comments