TextMapper extends SingleColumnMapper.SingleFieldMapper<String> { @Override public String toString() { return toStringHelper(this).add("analyzer", analyzer).toString(); } TextMapper(String field, String column, Boolean validated, String analyzer); @Override Optional<Field> indexedField(String name, String value); @Override Optional<Field> sortedField(String name, String value); @Override SortField sortField(String name, boolean reverse); @Override String toString();  }
@Test public void testToString() { TextMapper mapper = textMapper().validated(true).analyzer("English").build("field"); assertEquals("Method #toString is wrong", "TextMapper{field=field, validated=true, column=field, analyzer=English}", mapper.toString()); }