Skip to content

Instantly share code, notes, and snippets.

@nootn
Created February 5, 2013 12:01
Show Gist options
  • Save nootn/4714048 to your computer and use it in GitHub Desktop.
Save nootn/4714048 to your computer and use it in GitHub Desktop.
MiniProfiler.Windows IOC and AOP #4
private static void Main(string[] args)
{
//Configure building blocks
ConfigureIocAndAop();
//Start profiling
ConsoleProfiling.Start();
//Run the application, the log is all behind the IConsoleApplication's Run method so it can be easily unit tested
var app = _container.Resolve<IConsoleApplication>();
app.Run();
//Stop profiling and show results
Console.WriteLine(ConsoleProfiling.StopAndGetConsoleFriendlyOutputStringWithSqlTimings());
//Allow viewing of results
Console.WriteLine("... press 'Enter' to exit process ...");
Console.ReadLine();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment