### Question:
StringConverter implements AtlasConverter<String> { @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.STRING) public String toString(String value, String sourceFormat, String targetFormat) { if (value == null) { return null; } return new String(value); }  @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.DECIMAL, concerns = AtlasConversionConcern.FORMAT) BigDecimal toBigDecimal(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.BIG_INTEGER, concerns = AtlasConversionConcern.FORMAT) BigInteger toBigInteger(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.BOOLEAN, concerns = AtlasConversionConcern.CONVENTION) Boolean toBoolean(String value, String sourceFormat, String targetFormat); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.BYTE, concerns = { AtlasConversionConcern.RANGE, AtlasConversionConcern.FORMAT, AtlasConversionConcern.FRACTIONAL_PART}) Byte toByte(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.CHAR, concerns = AtlasConversionConcern.RANGE) Character toCharacter(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.DATE_TIME) Date toDate(String date, String sourceFormat, String targetFormat); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.DOUBLE, concerns = { AtlasConversionConcern.FORMAT, AtlasConversionConcern.RANGE }) Double toDouble(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.FLOAT, concerns = { AtlasConversionConcern.FORMAT, AtlasConversionConcern.RANGE }) Float toFloat(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.INTEGER, concerns = { AtlasConversionConcern.FORMAT, AtlasConversionConcern.RANGE, AtlasConversionConcern.FRACTIONAL_PART }) Integer toInteger(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.DATE) LocalDate toLocalDate(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.TIME) LocalTime toLocalTime(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.DATE_TIME) LocalDateTime toLocalDateTime(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.LONG, concerns = { AtlasConversionConcern.FORMAT, AtlasConversionConcern.RANGE, AtlasConversionConcern.FRACTIONAL_PART }) Long toLong(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.SHORT, concerns = { AtlasConversionConcern.FORMAT, AtlasConversionConcern.RANGE, AtlasConversionConcern.FRACTIONAL_PART }) Short toShort(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.STRING) String toString(String value, String sourceFormat, String targetFormat); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.NUMBER, concerns = { AtlasConversionConcern.FORMAT }) Number toNumber(String value); @AtlasConversionInfo(sourceType = FieldType.STRING, targetType = FieldType.DATE_TIME_TZ) ZonedDateTime toZonedDateTime(String value);  }### Answer:
@Test public void convertToString() { String zero = "0"; String converted = converter.toString(zero, null, null); assertNotNull(converted); assertNotSame(converted, zero); assertTrue("0".equals(converted)); }
@Test public void convertToStringNull() { String s = converter.toString(null, null, null); assertNull(s); }