Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions release-notes/CREDITS
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ Authors:

Contributors:

# 3.0.0-rc3 (not yet released)
WrongWrong (@k163377)
* #945: Replace JacksonXmlRootElement used in the test with JsonRootName

# 3.0.0-rc2 (not yet released)

WrongWrong (@k163377)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
package tools.jackson.module.kotlin.test.github

import com.fasterxml.jackson.annotation.JsonRootName
import tools.jackson.databind.exc.InvalidDefinitionException
import tools.jackson.dataformat.xml.XmlMapper
import tools.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper
import tools.jackson.dataformat.xml.annotation.JacksonXmlProperty
import tools.jackson.dataformat.xml.annotation.JacksonXmlRootElement
import tools.jackson.module.kotlin.kotlinModule
import tools.jackson.module.kotlin.test.expectFailure
import org.junit.jupiter.api.Test
import kotlin.test.assertEquals

class TestGithub153 {
@JacksonXmlRootElement(localName = "MyPojo")
@JsonRootName("MyPojo")
class MyPojo {
@JacksonXmlElementWrapper(localName = "elements")
@JacksonXmlProperty(localName = "element")
Expand All @@ -23,7 +23,7 @@ class TestGithub153 {
var value: String? = null
}

@JacksonXmlRootElement(localName = "MyPojo")
@JsonRootName("MyPojo")
data class MyDataPojo (
@JacksonXmlElementWrapper(localName = "elements")
@JacksonXmlProperty(localName = "element")
Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
package tools.jackson.module.kotlin.test.github.failing

import com.fasterxml.jackson.annotation.JsonIgnoreProperties
import com.fasterxml.jackson.annotation.JsonRootName
import tools.jackson.databind.exc.InvalidDefinitionException
import tools.jackson.dataformat.xml.XmlMapper
import tools.jackson.dataformat.xml.annotation.JacksonXmlProperty
import tools.jackson.dataformat.xml.annotation.JacksonXmlRootElement
import tools.jackson.dataformat.xml.annotation.JacksonXmlText
import tools.jackson.module.kotlin.readValue
import tools.jackson.module.kotlin.test.expectFailure
import tools.jackson.module.kotlin.kotlinModule
import org.junit.jupiter.api.Test

class TestGithub138 {
@JacksonXmlRootElement(localName = "sms")
@JsonRootName("sms")
@JsonIgnoreProperties(ignoreUnknown = true)
data class Sms(
@JacksonXmlProperty(localName = "Phone", isAttribute = true)
Expand Down