We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(note: copied from FasterXML/jackson-module-kotlin#335)
Looks like following test case, first found with Kotlin, fails:
public class ExternalPropertyTypeShouldBeNullTest { static class Box { public String type; public Fruit fruit; public Box(@JsonProperty("type") String type, @JsonTypeInfo(use = Id.NAME, include = As.EXTERNAL_PROPERTY, property = "type") @JsonSubTypes({@Type(value = Orange.class, name = "orange")}) @JsonProperty("fruit") Fruit fruit) { this.type = type; this.fruit = fruit; } } interface Fruit{} static class Orange implements Fruit { public String name; public String color; public Orange(@JsonProperty("name") String name, @JsonProperty("name") String color) { this.name = name; this.color = color; } } private final ObjectMapper MAPPER = new ObjectMapper(); @Test public void testDeserializationNull() throws Exception { MAPPER.disable(DeserializationFeature.FAIL_ON_MISSING_EXTERNAL_TYPE_ID_PROPERTY); Box deserOrangeBox = MAPPER.readValue("{\"type\":null,\"fruit\":null}}", Box.class); assertNull(deserOrangeBox.fruit); assertNull(deserOrangeBox.type); // error: "expected null, but was:<null>" } }
The text was updated successfully, but these errors were encountered:
Fix ref to issue #3008 (NOT #3005)
0df9053
No branches or pull requests
(note: copied from FasterXML/jackson-module-kotlin#335)
Looks like following test case, first found with Kotlin, fails:
The text was updated successfully, but these errors were encountered: