### Question:
BooleanConverter implements AtlasConverter<Boolean> { @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.LONG) public Long toLong(Boolean value) { return value != null ? (value ? 1L : 0L) : null; }  @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.DECIMAL) BigDecimal toBigDecimal(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.BIG_INTEGER) BigInteger toBigInteger(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.BOOLEAN) Boolean toBoolean(Boolean value, String sourceFormat, String targetFormat); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.BYTE) Byte toByte(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.CHAR) Character toCharacter(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.DOUBLE) Double toDouble(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.FLOAT) Float toFloat(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.INTEGER) Integer toInteger(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.LONG) Long toLong(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.NUMBER) Number toNumber(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.SHORT) Short toShort(Boolean value); @AtlasConversionInfo(sourceType = FieldType.BOOLEAN, targetType = FieldType.STRING, concerns = { AtlasConversionConcern.CONVENTION }) String toString(Boolean value, String sourceFormat, String targetFormat);  }### Answer:
@Test public void convertToLong() { Boolean t = Boolean.TRUE; Boolean f = Boolean.FALSE; Long l = converter.toLong(t); assertNotNull(l); assertEquals(1, l.longValue()); l = converter.toLong(f); assertNotNull(l); assertEquals(0, l.longValue()); }
@Test public void convertToLongNull() { Boolean t = null; Long l = converter.toLong(t); assertNull(l); }