Hm... I did find out it's Castle DynamicProxy's limitation (and
CLR's)...
I was wondering if there is a possibility of doing:
//Pseudo Code
IEventManager manager =
MockRepository.GenerateStub<IEventManager>(new EventManager()); //
Supply original object
manager.Stub(x=>x.SomeMethod()).Return(delegate() { //Do something
here }); //Stub the method that throws expection
Right now, I suspect, I need to mock the interface and stub all the
methods and route the calls to the original object manually.
This could be cumbersome if the class being stubbed has too many
methods/properties.
Regards, Vyas
> > partialStub.SomeMethod();- Hide quoted text -
>
> - Show quoted text -