Class EnsembleStartStopServiceManagerTest


  • @SpringBootTest(classes=Config.class)
    @TestPropertySource(locations="classpath:iipecosphere.yml")
    @ContextConfiguration(initializers=Initializer.class)
    @Import(de.iip_ecosphere.platform.services.spring.SpringCloudServiceSetup.class)
    public class EnsembleStartStopServiceManagerTest
    extends AbstractTestServiceManager
    Tests SpringCloudServiceManager. We assume that the test artifacts are prepared for MQTT v3.
    Author:
    Holger Eichelberger, SSE
    • Field Detail

      • BROKER

        private static final de.iip_ecosphere.platform.support.ServerAddress BROKER
    • Constructor Detail

      • EnsembleStartStopServiceManagerTest

        public EnsembleStartStopServiceManagerTest()
    • Method Detail

      • init

        public static void init()
        Initializes the test by starting an embedded AMQP server. Requires the Qpid configuration file in src/test. We do not rely on MQTT here, because Moquette is not stable enough and Hivemq requires JDK 11.
      • shutdown

        public static void shutdown()
        Shuts down client and test server.
      • testEnsembleStartStop

        public void testEnsembleStartStop()
                                   throws java.util.concurrent.ExecutionException,
                                          java.io.IOException
        Tests a simple start-stop cycle of the SpringCloudServiceManager in one process as an ensemble.
        Throws:
        java.util.concurrent.ExecutionException - shall not occur for successful test
        java.io.IOException - shall not occur for successful test