Class LifecycleHandlerTest


  • public class LifecycleHandlerTest
    extends java.lang.Object
    Tests LifecycleDescriptor and LifecycleHandler.
    Author:
    Holger Eichelberger, SSE
    • Field Detail

      • cmdArgs

        private static java.lang.String[] cmdArgs
      • startupCount

        private static int startupCount
      • shutdownCount

        private static int shutdownCount
      • shutdownHookCount

        private static int shutdownHookCount
      • shutdownHookCalledCount

        private static int shutdownHookCalledCount
      • countDescriptors

        private static int countDescriptors
    • Constructor Detail

      • LifecycleHandlerTest

        public LifecycleHandlerTest()
    • Method Detail

      • testLifecycleHandler

        public void testLifecycleHandler()
        Tests the lifecycle handler with no waiting.
      • testLifecycleHandlerWaiting

        public void testLifecycleHandlerWaiting()
        Tests the lifecycle handler with waiting and shutdown by hook. May end up in an endless loop in case of bugs. LifecycleHandlerTest.LcDesc2 shall terminate the loop after 10 iterations.
      • testLifecycleHandlerWaitingShutdown

        public void testLifecycleHandlerWaitingShutdown()
        Tests the lifecycle handler with waiting and shutdown at the end. May end up in an endless loop in case of bugs. LifecycleHandlerTest.LcDesc2 shall terminate the loop after 10 iterations.