Skip to content

Instantly share code, notes, and snippets.

@michalczukm
Last active August 29, 2015 14:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save michalczukm/cf191d50a6095d4c35b9 to your computer and use it in GitHub Desktop.
Save michalczukm/cf191d50a6095d4c35b9 to your computer and use it in GitHub Desktop.
Act Test method ignoring not exceptions of type
public static class TestHelper
{
public static void ActIgnoringExceptions<TException>(Action act) where TException : Exception
{
try
{
act.Invoke();
}
catch (TException ex)
{
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment