@Test
    public void idAsAliasForPutTest()  throws IOException{
        JsonReader r = createReader("""
                                    {
                                      "id": "id:unittest:smoke::doc1",
                                      "fields": {
                                        "something": "smoketest",
                                        "flag": true,
                                        "nalle": "bamse"
                                      }
                                    }
                                    """);
        DocumentParseInfo parseInfo = r.parseDocument().get();
        DocumentType docType = r.readDocumentType(parseInfo.documentId);
        DocumentPut put = new DocumentPut(new Document(docType, parseInfo.documentId));
        boolean fullyApplied = new VespaJsonDocumentReader(false).readPut(parseInfo.fieldsBuffer, put);
        assertTrue(fullyApplied);
        smokeTestDoc(put.getDocument());
    }
Basic test of JSON streams to Vespa document instances.

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