public virtual void Dispose()
 {
     if (UserCredential != null)
     {
         // Delete the test user
         var principalManager =
             new LocalPrincipalManager();
         principalManager.DeleteUser(UserCredential.UserName);
     }
 }
 public void Dispose()
 {
     jobObject.Dispose();
     userManager.DeleteUser(username);
     try
     {
         guardProcess.Kill();
     }
     catch (System.InvalidOperationException)
     {
     }
 }
Esempio n. 3
0
        private static void DeleteUser(string userName)
        {
            var principalManager = new LocalPrincipalManager();

            principalManager.DeleteUser(userName);
        }