### Question:
LatencyUtilsConfigInitializer implements ApplicationContextInitializer<ConfigurableApplicationContext> { @Override public void initialize(@Nonnull ConfigurableApplicationContext applicationContext) { if (System.getProperties().getProperty(PROPERTY_KEY) == null) { System.getProperties().setProperty(PROPERTY_KEY, "false"); } }  @Override void initialize(@Nonnull ConfigurableApplicationContext applicationContext);  }### Answer:
@Test public void shouldSetSystemPropertyWhenPropertyNotSet() { System.getProperties().remove(PROPERTY_KEY); assertNull(System.getProperties().getProperty(PROPERTY_KEY)); LatencyUtilsConfigInitializer latencyUtilsConfigInitializer = new LatencyUtilsConfigInitializer(); latencyUtilsConfigInitializer.initialize(applicationContext); assertEquals("false", System.getProperties().getProperty(PROPERTY_KEY)); }
@Test public void shouldNotSetSystemPropertyWhenPropertyIsSetFromBefore() { System.getProperties().remove(PROPERTY_KEY); String value = "RandomValue"; System.getProperties().setProperty(PROPERTY_KEY, value); assertEquals(value, System.getProperties().getProperty(PROPERTY_KEY)); LatencyUtilsConfigInitializer latencyUtilsConfigInitializer = new LatencyUtilsConfigInitializer(); latencyUtilsConfigInitializer.initialize(applicationContext); assertEquals(value, System.getProperties().getProperty(PROPERTY_KEY)); }