Hello,

I have a question that is not directly related to RhinoMocks so sorry
if I bother you with that. I was asked to refactor and implement unit
tests in a legacy code that was developed without any unit tests. I
work with NUnit and RhinoMocks.

The first problem I was faced to is that all fonctionals layers in a
code are mixes. Business Objects deal with persistance, GUI deals with
persistance end busines object, busines logic in GUI, data
manipulation in Business objects and son on. ONE BIG MESS. The most
impressive is inheritance on several levels. So what's the point.

In my persistance layer I have objects that's deals with data. I don't
want to test it.
My each Business objects inheritate directly or indirectly from a
PersistentObject.

I need to test a logic in my business objects that inheritate from my
persistance layer.

For exemple:

public class BOCars: PersistentObject
{
     public bool MethodIWantToTest()
     {
        // My logic

       baseclassMethodFromPersistantObject();

       // more logic
     }
}

I would like to remove dependence from PersistentObject to test my
logic in "MethodIWantToTest()". What's the best way to do it using
RhinoMocks. Thanks for your advaice and help.

TJA
--~--~---------~--~----~------------~-------~--~----~
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