Stubbing Event Listeners in .NET

I’ve been trying Rhino Mocks recently as an alternative to NMock for my unit tests’ mocking and stubbing needs.

One thing I’ve just needed to do is be able test an event listener (i.e. stub out a call from an event publisher) and found a good write-up here.

I’m still not completely won over by Rhino Mocks but I do like the .NET 2 support it has so I’m going to persist a little longer.

Advertisements