May 242012
 

NOTE: I have since solved this problem with a Ninject module that makes things much simpler. Check out this post for details.

This post describes a pattern I came up with for providing logging in an application is a very elegant way, with consumers of loggers able to use loggers that are injected via property injection. But, at test time if the logger is null, a NullReferenceException is prevented so that tests can be executed without having to provide a mocked logging interface.
Continue reading »