Skip to content

Commit 0003d60

Browse files
committed
fix one of the tests broken by recent changes in jackson-databind v3
1 parent f0e64b3 commit 0003d60

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/test/scala/tools/jackson/module/scala/deser/PrimitiveContainerTest.scala

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package tools.jackson.module.scala.deser
22

33
import tools.jackson.core.`type`.TypeReference
4-
import tools.jackson.databind.DatabindException
4+
import tools.jackson.core.exc.InputCoercionException
55
import tools.jackson.databind.annotation.JsonDeserialize
66
import tools.jackson.module.scala.deser.OptionWithNumberDeserializerTest.{OptionLong, OptionLongWithDefault}
77

@@ -57,7 +57,8 @@ class PrimitiveContainerTest extends DeserializationFixture
5757
}
5858

5959
it should "enforce type constraints" in { f =>
60-
val thrown = intercept[DatabindException] {
60+
// InputCoercionException in Jackson 3 - was DatabindException in Jackson 2
61+
val thrown = intercept[InputCoercionException] {
6162
f.readValue("""{"value":9223372036854775807}""", new TypeReference[AnnotatedOptionInt] {}).value.get
6263
}
6364
thrown.getMessage should startWith ("Numeric value (9223372036854775807) out of range")

0 commit comments

Comments
 (0)