CleanUpStatics() public static method

Performs cleanup activities so the application can be shut down.
public static CleanUpStatics ( ) : void
return void
Example #1
0
        /// <summary>
        /// Call this from the TearDown method in your NUnit initializer. Besides this call, there should be no other code in the method.
        /// </summary>
        public static void CleanUpStatics()
        {
            if (appInitializer != null)
            {
                appInitializer.CleanUpStatics();
            }

            GlobalInitializationOps.CleanUpStatics();
        }
Example #2
0
 /// <summary>
 /// Call this from Application_Exit. Besides this call, there should be no other code in the method.
 /// </summary>
 public static void CleanUpStatics()
 {
     exceptionHandlerEnabled = false;
     if (!GlobalInitializationOps.SecondaryInitFailed)
     {
         TelemetryStatics.ExecuteBlockWithStandardExceptionHandling(
             () => {
             if (appInitializer != null)
             {
                 appInitializer.CleanUpStatics();
             }
         });
     }
     GlobalInitializationOps.CleanUpStatics();
 }