Hi,

I want to mock events in my MVP application
I have this code

            IToolbar toolbar = Mocks.StrictMock<IToolbar>();
            toolbar.SaveEventHandler += null;
            IEventRaiser raiser = LastCall.IgnoreArguments
().GetEventRaiser(); //exception here

But I have exception
System.InvalidOperationException: Previous method
'IToolbar.get_SaveEventHandler();' requires a return value or an
exception to throw.

I can't understand what is wrong. Should I return somthing?.

Does anybody can help me to understand it?
How can I use mocking for events in Rhino Mocks 3.5. All examples than
I tryed was not working.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Rhino.Mocks" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/RhinoMocks?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to