-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #257 from ProjectMapK/develop
Release 2024-12-29 11:02:56 +0000
- Loading branch information
Showing
12 changed files
with
101 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# To get started with Dependabot version updates, you'll need to specify which | ||
# package ecosystems to update and where the package manifests are located. | ||
# Please see the documentation for all configuration options: | ||
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file | ||
|
||
version: 2 | ||
|
||
updates: | ||
- package-ecosystem: "gradle" | ||
directory: "/" | ||
schedule: | ||
interval: "weekly" | ||
# Friday 19:00 JST | ||
day: "saturday" | ||
time: "04:00" | ||
groups: | ||
dependencies: | ||
patterns: | ||
- "*" | ||
ignore: | ||
# The version of Kotlin is fixed to the lowest, so it is not subject to automatic updates | ||
- dependency-name: "kotlin" | ||
- dependency-name: "kotlinx-metadata-jvm" | ||
# linter is not subject to automatic renewal as it will be migrated to detekt in the future | ||
- dependency-name: "org.jmailen.kotlinter" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
src/test/kotlin/io/github/projectmapk/jackson/module/kogera/zPorted/test/github/GitHub841.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package io.github.projectmapk.jackson.module.kogera.zPorted.test.github | ||
|
||
import com.fasterxml.jackson.annotation.JsonCreator | ||
import com.fasterxml.jackson.annotation.JsonInclude | ||
import com.fasterxml.jackson.databind.ObjectMapper | ||
import io.github.projectmapk.jackson.module.kogera.readValue | ||
import io.github.projectmapk.jackson.module.kogera.registerKotlinModule | ||
import org.junit.jupiter.api.Assertions.assertEquals | ||
import org.junit.jupiter.api.Test | ||
|
||
class GitHub841 { | ||
object Foo { | ||
override fun toString(): String = "Foo()" | ||
|
||
@JvmStatic | ||
@JsonCreator | ||
fun deserialize(): Foo { | ||
return Foo | ||
} | ||
} | ||
|
||
private val mapper = ObjectMapper() | ||
.setSerializationInclusion(JsonInclude.Include.NON_ABSENT) | ||
.registerKotlinModule() | ||
|
||
@Test | ||
fun shouldDeserializeSimpleObject() { | ||
val value = Foo | ||
val serialized = mapper.writeValueAsString(value) | ||
val deserialized = mapper.readValue<Foo>(serialized) | ||
|
||
assertEquals(value, deserialized) | ||
} | ||
} |