Last active
August 1, 2017 03:47
-
-
Save patbonecrusher/762cc3d9105ac676d66ccfd8dc503672 to your computer and use it in GitHub Desktop.
To know if running inside nunit #dotnet #tdd
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static readonly bool IsRunningFromNUnit = | |
AppDomain.CurrentDomain.GetAssemblies().Any( | |
a => a.FullName.ToLowerInvariant().StartsWith("nunit.framework", StringComparison.Ordinal)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment