### Question:
DataExtractorProcessorOptions extends ProcessorOptions { public DataExtractorProcessorOptions() { super(); } DataExtractorProcessorOptions();  DataExtractorProcessorOptions(DataExtractorProcessorOptions other);  DataExtractorProcessorOptions(ProcessorOptions other);  DataExtractorProcessorOptions(JsonObject json); JsonObject getExtract(); DataExtractorProcessorOptions setExtract(JsonObject extract); @Override String getName(); @Override DataExtractorProcessorOptions setName(String name); @Override String getType(); @Override DataExtractorProcessorOptions setType(String type); @Override Integer getInstances(); @Override DataExtractorProcessorOptions setInstances(Integer instances); @Override JsonObject toJson(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); static final JsonObject DEFAULT_EXTRACT; }### Answer:
@Test @DisplayName("Validate Data Extractor options") void testDataExtractorProcessorOptions() { new DataExtractorProcessorOptionsConverter(); String badStr = "{\"name\": 10, \"type\": 20, \"extract\": false}"; String optStr = "{\"instances\":1, \"name\":\"name\", \"type\": \"type\", \"extract\":{\"field\":\"value\"}}"; ProcessorOptions optPump = new ProcessorOptions(new JsonObject(optStr)); DataExtractorProcessorOptions optNull = new DataExtractorProcessorOptions() .setName(null) .setType(null) .setExtract(null); DataExtractorProcessorOptions optObj = new DataExtractorProcessorOptions() .setName("name") .setType("type") .setExtract(obj().put("field", "value")); JsonObject optJson = new JsonObject(optStr); assertThat(new DataExtractorProcessorOptions(new JsonObject(badStr))).isEqualTo(new DataExtractorProcessorOptions()); assertThat(optNull.toJson()).isEqualTo(obj().put("instances", 1)); assertThat(optObj).isEqualTo(optObj); assertThat(optObj).isNotEqualTo(optNull); assertThat(optObj).isEqualTo(new DataExtractorProcessorOptions(optJson)); assertThat(optObj).isEqualTo(new DataExtractorProcessorOptions(optObj)); assertThat(optObj.toString()).isEqualTo(new DataExtractorProcessorOptions(optJson).toString()); assertThat(optObj.hashCode()).isEqualTo(new DataExtractorProcessorOptions(optJson).hashCode()); assertThat(optObj).isNotEqualTo(null); assertThat(optObj).isNotEqualTo(new Object()); assertThat(optObj.toJson()).isEqualTo(optJson); assertThat(optPump) .isEqualToComparingOnlyGivenFields(new DataExtractorProcessorOptions(optPump), "name", "type"); }