@Test
public void castToDouble() {

    assertEquals(10d, TypeUtils.castToDouble(Integer.valueOf("10")));
    assertEquals(10d, TypeUtils.castToDouble(Double.valueOf("10")));
    assertEquals(10d, TypeUtils.castToDouble("10"));
    assertEquals(10d, TypeUtils.castToDouble("10", 10d));
    assertEquals(10d, TypeUtils.castToDouble(null, 10d));
}