@Test
    public void readDocumentWithMissingFieldsField() {
        assertEquals("document is missing the required \"fields\" field",
                     assertThrows(IllegalArgumentException.class,
                                  () -> createReader("{ }").readSingleDocumentStreaming(DocumentOperationType.PUT,
                                                                                        "id:unittest:testnull::whee"))
                             .getMessage());
    }
Basic test of JSON streams to Vespa document instances.

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