### Question:
ConfigurationUtils { public static long systemProperty(String name, long defaultValue) { String propertyValue = System.getProperty(name); if (propertyValue != null) { try { return Long.parseLong(propertyValue.trim()); } catch (NumberFormatException ex) { LOGGER.error("Failed parsing {} value.", name, ex); } } return defaultValue; } private  ConfigurationUtils(); static long systemProperty(String name, long defaultValue); static String systemProperty(String name, String defaultValue);  }### Answer:
@Test public void testSystemProperty() { final String propertyName = "testSystemProperty"; assertEquals(10, ConfigurationUtils.systemProperty(propertyName, 10)); assertEquals("10", ConfigurationUtils.systemProperty(propertyName, "10")); System.setProperty(propertyName, "invalid-value"); assertEquals(10, ConfigurationUtils.systemProperty(propertyName, 10)); System.setProperty(propertyName, "123"); assertEquals(123, ConfigurationUtils.systemProperty(propertyName, 10)); assertEquals("123", ConfigurationUtils.systemProperty(propertyName, "10")); System.setProperty(propertyName, ""); assertEquals("10", ConfigurationUtils.systemProperty(propertyName, "10")); System.setProperty(propertyName, " "); assertEquals("10", ConfigurationUtils.systemProperty(propertyName, "10")); System.setProperty(propertyName, " 123 "); assertEquals("123", ConfigurationUtils.systemProperty(propertyName, "10")); }