private DocumentUpdate parseUpdate(String json) throws IOException {
        InputStream rawDoc = new ByteArrayInputStream(Utf8.toBytes(json));
        JsonReader r = new JsonReader(types, rawDoc, parserFactory);
        DocumentParseInfo parseInfo = r.parseDocument().get();
        DocumentType docType = r.readDocumentType(parseInfo.documentId);
        DocumentUpdate update = new DocumentUpdate(docType, parseInfo.documentId);
        new VespaJsonDocumentReader(false).readUpdate(parseInfo.fieldsBuffer, update);
        return update;
    }
Basic test of JSON streams to Vespa document instances.

@author Steinar Knutsen
@author bratseth
document/src/test/java/com/yahoo/document/json/JsonReaderTestCase.java