### Question:
ConfigurationUtils { public static Integer tryGetGlobalIntegerProperty(String key, Integer defaultValue) { try { String value = System.getenv(formatEnvironmentVariable(key)); if (value == null) { return tryGetIntegerProperty(key, defaultValue); } else { return Integer.parseInt(value); } } catch (SecurityException | NumberFormatException e) { logger.error("Could not get value of global property {} due to SecurityManager. Using default value.", key, e); return defaultValue; } } private  ConfigurationUtils(); static String formatEnvironmentVariable(String key); static String tryGetGlobalProperty(String key, String defaultValue); static String tryGetGlobalProperty(String key); static Integer tryGetGlobalIntegerProperty(String key, Integer defaultValue); static Integer tryGetGlobalIntegerProperty(String key);  }### Answer:
@Test public void testExistingTryGetIntegerProperty() { System.setProperty(TEST_PROPERTY_NAME, "123456"); assertThat(ConfigurationUtils.tryGetGlobalIntegerProperty(TEST_PROPERTY_NAME)).isEqualTo(123456); }
@Test public void testNonExistingTryGetIntegerProperty() { assertThat(ConfigurationUtils.tryGetGlobalIntegerProperty(TEST_PROPERTY_NAME)).isNull(); }
@Test public void testNonExistingTryGetIntegerPropertyWithDefaultValue() { assertThat(ConfigurationUtils.tryGetGlobalIntegerProperty(TEST_PROPERTY_NAME, 123)).isEqualTo(123); }