### Question:
ContainerType implements Type { @Override public JsonNode toJson(JsonNodeFactory factory, Object value) { if (value == null) { return factory.nullNode(); } else { throw new UnsupportedOperationException(MetadataConstants.ERR_TO_JSON_NOT_SUPPORTED); } } ContainerType(String name); @Override String getName(); @Override boolean supportsEq(); @Override boolean supportsOrdering(); @Override int compare(Object v1, Object v2); @Override Object cast(Object v); @Override JsonNode toJson(JsonNodeFactory factory, Object value); @Override Object fromJson(JsonNode value); @Override boolean equals(Object obj); @Override int hashCode();  }### Answer:
@Test(expected = UnsupportedOperationException.class) public void testToJson() { type.toJson(JsonNodeFactory.withExactBigDecimals(true), new Object()); }