From 3f4df6aa5ce887942ec8ce3384f7322ee27ea602 Mon Sep 17 00:00:00 2001 From: Tatu Saloranta Date: Wed, 18 Sep 2013 11:16:09 -0700 Subject: [PATCH] Fix incorrect bug id in comments; fixed #25, not 24 --- release-notes/VERSION | 2 +- .../module/jaxb/test/TestElementWrapper.java | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/release-notes/VERSION b/release-notes/VERSION index cf780d0..758f095 100644 --- a/release-notes/VERSION +++ b/release-notes/VERSION @@ -1,7 +1,7 @@ Project: jackson-module-jaxb-annotations Version: 2.3.0 (xx-xxx-2013) -#24: @XmlElementWrapper() should work wrt USE_WRAPPER_NAME_AS_PROPERTY_NAME, +#25: @XmlElementWrapper() should work wrt USE_WRAPPER_NAME_AS_PROPERTY_NAME, use underlying "default" property name ------------------------------------------------------------------------ diff --git a/src/test/java/com/fasterxml/jackson/module/jaxb/test/TestElementWrapper.java b/src/test/java/com/fasterxml/jackson/module/jaxb/test/TestElementWrapper.java index c375157..658f490 100644 --- a/src/test/java/com/fasterxml/jackson/module/jaxb/test/TestElementWrapper.java +++ b/src/test/java/com/fasterxml/jackson/module/jaxb/test/TestElementWrapper.java @@ -50,8 +50,8 @@ static class Bean13 public int id; } - // [Issue#24]: should also work with 'default' name - static class Bean24 + // [Issue#25]: should also work with 'default' name + static class Bean25 { @XmlElement(name="element") // This would work @@ -59,8 +59,8 @@ static class Bean24 @XmlElementWrapper public List values; - public Bean24() { } - public Bean24(int... v0) { + public Bean25() { } + public Bean25(int... v0) { values = new ArrayList(); for (int v : v0) { values.add(v); @@ -113,18 +113,18 @@ public void testWrapperRenaming() throws Exception assertEquals("{\"wrap\":3}", mapper.writeValueAsString(input)); } - // [Issue#24] + // [Issue#25] public void testWrapperDefaultName() throws Exception { ObjectMapper mapper = getJaxbMapper(); mapper = getJaxbMapper(); mapper.enable(MapperFeature.USE_WRAPPER_NAME_AS_PROPERTY_NAME); - Bean24 input = new Bean24(1, 2, 3); + Bean25 input = new Bean25(1, 2, 3); final String JSON = "{\"values\":[1,2,3]}"; assertEquals(JSON, mapper.writeValueAsString(input)); // plus needs to come back ok as well - Bean24 result = mapper.readValue(JSON, Bean24.class); + Bean25 result = mapper.readValue(JSON, Bean25.class); assertNotNull(result); assertNotNull(result.values); assertEquals(3, result.values.size());