Skip to content

Commit bb734fc

Browse files
committed
Merge branch '2.12'
2 parents 58ae043 + e57b72a commit bb734fc

File tree

4 files changed

+6
-13
lines changed

4 files changed

+6
-13
lines changed

datetime/src/test/java/com/fasterxml/jackson/datatype/jsr310/TestOffsetDateTimeDeserialization.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -133,8 +133,7 @@ public void testDeserializationAsArrayDisabled() throws Throwable
133133
READER.readValue("['2000-01-01T12:00+00']");
134134
fail("expected JsonMappingException");
135135
} catch (JsonMappingException e) {
136-
verifyException(e, "Cannot deserialize");
137-
verifyException(e, "START_ARRAY token");
136+
verifyException(e, "Cannot deserialize value of type `java.time.OffsetDateTime` from Array value");
138137
}
139138
}
140139

@@ -145,8 +144,7 @@ public void testDeserializationAsEmptyArrayDisabled() throws Throwable
145144
READER.readValue("[]");
146145
fail("expected JsonMappingException");
147146
} catch (JsonMappingException e) {
148-
verifyException(e, "Cannot deserialize");
149-
verifyException(e, "START_ARRAY token");
147+
verifyException(e, "Cannot deserialize value of type `java.time.OffsetDateTime` from Array value");
150148
}
151149
try {
152150
READER.with(DeserializationFeature.UNWRAP_SINGLE_VALUE_ARRAYS)

datetime/src/test/java/com/fasterxml/jackson/datatype/jsr310/deser/DurationDeserTest.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -329,10 +329,7 @@ public void testDeserializationAsEmptyArrayDisabled() throws Throwable
329329
READER.readValue("[]");
330330
fail("expected MismatchedInputException");
331331
} catch (MismatchedInputException e) {
332-
// 17-Aug-2019, tatu: Message differs between 2.10 and 3.0...
333-
verifyException(e, "Cannot deserialize value of type");
334-
verifyException(e, "java.time.Duration");
335-
verifyException(e, "out of START_ARRAY");
332+
verifyException(e, "Cannot deserialize value of type `java.time.Duration` from Array value");
336333
}
337334
try {
338335
READER.with(DeserializationFeature.UNWRAP_SINGLE_VALUE_ARRAYS)

datetime/src/test/java/com/fasterxml/jackson/datatype/jsr310/deser/ZoneOffsetDeserTest.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,8 +95,7 @@ public void testDeserializationAsArrayDisabled() throws Throwable
9595
READER.readValue("[\"+0300\"]");
9696
fail("expected MismatchedInputException");
9797
} catch (MismatchedInputException e) {
98-
verifyException(e, "Cannot deserialize");
99-
verifyException(e, "out of START_ARRAY");
98+
verifyException(e, "Cannot deserialize value of type `java.time.ZoneOffset` from Array value");
10099
}
101100
}
102101

@@ -107,8 +106,7 @@ public void testDeserializationAsEmptyArrayDisabled() throws Throwable
107106
READER.readValue("[]");
108107
fail("expected MismatchedInputException");
109108
} catch (MismatchedInputException e) {
110-
verifyException(e, "Cannot deserialize");
111-
verifyException(e, "out of START_ARRAY");
109+
verifyException(e, "Cannot deserialize value of type `java.time.ZoneOffset` from Array value");
112110
}
113111
try {
114112
READER

datetime/src/test/java/com/fasterxml/jackson/datatype/jsr310/failing/LocalDateDeserTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@ public StrictWrapper() { }
2424
@Test(expected = InvalidFormatException.class)
2525
public void testStrictCustomFormat() throws Exception
2626
{
27-
StrictWrapper w = MAPPER.readValue("{\"value\":\"2019-11-31\"}", StrictWrapper.class);
27+
/*StrictWrapper w =*/ MAPPER.readValue("{\"value\":\"2019-11-31\"}", StrictWrapper.class);
2828
}
2929
}

0 commit comments

Comments
 (0)