### Question:
RecordImpl implements Record { @Override public void setChar(final String fieldName, final String value) { final long dataLength = getStructure().getField(fieldName).getDataLength(); if (value.length() > dataLength) { throw new ArrayIndexOutOfBoundsException( String.format("String data length exceeds maximum data length: %s > %s", Integer.toString(value.length()), Long.toString(dataLength))); } setValue(fieldName, value, DataType.CHARACTER); } RecordImpl(final String name, final Structure structure, final Record parent);   RecordImpl(final String name, final Structure structure, final Record parent,
            final RecordListImplFactory fixedListFactory, final DynamicRecordListImplFactory varListFactory,
            final RecordImplFactory recordFactory); @Override String getDeclaration(); @Override DynamicRecordList getDynamicList(final String fieldName); @Override short getI2(final String fieldName); @Override boolean getI2Boolean(final String fieldName); @Override int getI4(final String fieldName); @Override String getChar(final String fieldName); @Override Date getDQ8(final String fieldName); @Override double getF8(final String fieldName); @Override RecordList getList(final String fieldName); @Override String getName(); @Override int getNestedLevel(); @Override Record getRecord(final String fieldName); @Override Structure getStructure(); @Override DataType getType(final String fieldName); @Override String getVC(final String fieldName); @Override boolean hasMember(final String fieldName); @Override boolean isRoot(); @Override void setChar(final String fieldName, final String value); @Override void setDQ8(final String fieldName, final Date value); @Override void setI2(final String fieldName, final short value); @Override void setI2(final String fieldName, final boolean value); @Override void setI4(final String fieldName, final int value); @Override void setF8(final String fieldName, final double value); @Override void setVC(final String fieldName, final String value); @Override String toString();  }### Answer:
@Test public void testSetChar() { final String setValue = "I am a set value."; final RecordImpl record = new RecordImpl(ROOT_NAME, mockStructure(CHAR_FIELD), null); record.setChar(CHAR_FIELD.getName(), setValue); assertThat(record.getChar(CHAR_FIELD.getName())).isEqualTo(setValue); }