Package 

Class TestPropertiesInitializer

  • All Implemented Interfaces:
    org.springframework.context.ApplicationContextInitializer

    
    public final class TestPropertiesInitializer
     implements ApplicationContextInitializer<ConfigurableApplicationContext>
                        

    Allows to bundle particular properties within test jar and apply them automatically.

    For example, target production http client jar might require specifying client certificate by default. However, we might not need that in tests and allow to disable that restriction via particular property. Then we can bundle a file name like harmonysoft-http-test.properties into http-client.jar which suppresses certificate check.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      Unit initialize(ConfigurableApplicationContext context)
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • TestPropertiesInitializer

        TestPropertiesInitializer()
    • Method Detail

      • initialize

         Unit initialize(ConfigurableApplicationContext context)