I seen this post but I am sort of confused by it.
How can I mock Elmah's ErrorSignal routine?
I am looking at option 2
Create a wrapper class around the call to Raise and just mock out the wrapper class.
public class ErrorSignaler {
public virtual void SignalFromCurrentContext(Exception e) {
if (HttpContext.Current != null)
Elmah.ErrorSignal.FromCurrentContext().Raise(e);
}
}
I am kinda confused though by the fact that this does not seem to implement an interface and I am not really sure why it seems to be in place for some sort of inheritance.
Thanks