@Test
    public void testMissingOperation() {
        try {
            String jsonData = """
                              [
                                {
                                  "fields": {
                                    "actualarray": {
                                      "add": [
                                        "person",
                                        "another person"
                                      ]
                                    }
                                  }
                                }
                              ]""";

            new JsonReader(types, jsonToInputStream(jsonData), parserFactory).next();
            fail("Expected exception");
        }
        catch (IllegalArgumentException e) {
            assertEquals("Missing a document operation ('put', 'update' or 'remove')", e.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