### Question:
PebbleConfigurationProducer { @Produces public Properties pebbleConfiguration() { Properties pebbleProperties = loadFromFile("pebble.properties"); Stream.of(PebbleProperty.values()) .forEach(property -> property.systemPropertyValue().ifPresent(value -> pebbleProperties.put(property.key(), value)) ); return pebbleProperties; }  @Produces Properties pebbleConfiguration(); Properties loadFromFile(String fileName);  }### Answer:
@Test public void shouldReturnPebbleConfiguration() { Properties pebbleConfiguration = pebbleConfigurationProducer.pebbleConfiguration(); assertNotNull(pebbleConfiguration); assertEquals(pebbleConfiguration.getProperty("org.eclipse.krazo.ext.pebble.autoEscaping"), "true"); }
@Test public void shouldReturnPebbleConfiguration() { Properties pebbleConfiguration = pebbleConfigurationProducer.pebbleConfiguration(); assertNotNull(pebbleConfiguration); assertEquals(pebbleConfiguration.getProperty("org.mvcspec.ozark.ext.pebble.autoEscaping"), "true"); }
@Test public void systemPropertyShouldHaveHigherPriorityThanTheOneFromPropertyFile() { System.setProperty(PebbleProperty.AUTO_ESCAPING.key(), "false-override"); Properties pebbleConfiguration = pebbleConfigurationProducer.pebbleConfiguration(); assertNotNull(pebbleConfiguration); assertEquals(pebbleConfiguration.getProperty(PebbleProperty.AUTO_ESCAPING.key()), "false-override"); }