Bug 180392 [DataBinding] Add support for shorts, bytes, and BigDecimal to StringToNumberConverter
We need to add the appropriate API to StringToNumberConverter and NumberToStringConverter for short and bytes as their boxed types are Numbers as well.
tests/org.eclipse.jface.tests.databinding/src/org/eclipse/core/tests/databinding/conversion/NumberToStringConverterTest.java
String expected = numberFormat.format(input.floatValue());
		NumberToStringConverter converter = NumberToStringConverter
				.fromFloat(false);
		String result = (String) converter.convert(input);
		assertEquals(expected, result);
	}
	public void testConvertLongToString() throws Exception {
		Long input = new Long(1000l);
		String expected = integerFormat.format(input.longValue());
		NumberToStringConverter converter = NumberToStringConverter
				.fromLong(false);
		String result = (String) converter.convert(input);
		assertEquals(expected, result);
	}
	
	public void testConvertBigIntegerToString() throws Exception {
		BigInteger input = BigInteger.valueOf(1000);
		String expected = integerFormat.format(input);
		
		NumberToStringConverter converter = NumberToStringConverter.fromBigInteger();
		String result = (String) converter.convert(input);
		assertEquals(expected, result);
	}
	public void testNullSourceConvertsToEmptyString() throws Exception {
		NumberToStringConverter converter = NumberToStringConverter
				.fromInteger(false);
		assertEquals("", converter.convert(null));
	}
}