private void DisposeSingleConnection(ITest test)
        {
            if (test is TestFixture)
            {
                if (SingleConnectionAuthSpec != null)
                {
                    SingleConnectionAuthInfo.Dispose();
                }

                SharedSession.Dispose();
            }
        }
예제 #2
0
 private void DisposeAuthenticationInfo(ITest test)
 {
     if (test.Parent != null && test.Parent.Properties.ContainsKey(AuthenticationInfoPropertyName))
     {
         var valuesList = test.Parent.Properties[AuthenticationInfoPropertyName] as IList <object>;
         if (valuesList != null && valuesList.Count == 1 && valuesList.Single() as MultiItemAuthenticationInfo == authenticationInfo)
         {
             return;
         }
     }
     if (authenticationInfo != null && !string.IsNullOrEmpty(AuthenticationDataSpec))
     {
         authenticationInfo.Dispose();
         authenticationInfo = null;
     }
 }