### Question:
ConfigUtils { public String getStringValue2( Properties props, String propertyName1, String propertyName2, String defaultValue) { return expandVariables(props, propertyName1, null) .orElseGet(() -> expandVariables(props, propertyName2, null).orElse(defaultValue)); }  List<String> getNormalizedPackages(String packages); String getStringValue(Properties props, String propertyName, String defaultValue); String getStringValue2(
      Properties props, String propertyName1, String propertyName2, String defaultValue); Optional<String> getStringValue(Properties props, String propertyName); boolean getBooleanValue(Properties props, String key, boolean defaultValue); int getIntValue(Properties props, String key, int defaultValue); String getEnvVarName(String propertyName); String getSystemPropertyName(String key); List<File> getCommaSeparatedFileValues(String uriValues);  }### Answer:
@Test public void should_getStringValue2_key1() { Properties props = new Properties(); props.setProperty("key", "value"); assertThat(getStringValue2(props, "alternateKey", "key", "defaultValue"), is("value")); }
@Test public void should_getStringValue2_key2() { Properties props = new Properties(); props.setProperty("key", "value"); assertThat(getStringValue2(props, "key", "alternateKey", "defaultValue"), is("value")); }
@Test public void should_getStringValue2_default() { Properties props = new Properties(); props.setProperty("somekey", "value"); assertThat(getStringValue2(props, "key", "alternateKey", "defaultValue"), is("defaultValue")); }