use of com.fasterxml.jackson.core.exc.WrappedIOException in project jackson-core by FasterXML.
the class Fuzz32208UTF32ParseTest method testFuzz32208ViaParser.
public void testFuzz32208ViaParser() throws Exception {
final JsonFactory f = newStreamFactory();
JsonParser p = f.createParser(ObjectReadContext.empty(), DOC);
try {
assertToken(JsonToken.VALUE_STRING, p.nextToken());
String text = p.getText();
fail("Should not have passed; got text with length of: " + text.length());
} catch (WrappedIOException e) {
verifyException(e, "Invalid UTF-32 character ");
}
p.close();
}
Aggregations