rhino mocks - Mocking problem, public function calling private function -
I am having a funny problem I know that only public methods should be joking. But when I am calling a private method in the public system, and this private method is receiving data from a file, what should I do? I want to duplicate this private method so that I can go with a public method test.
I can make this public to work for the test, but this will not make any sense because it is private reason. I can also move everything to another class and make the function public there, but the reference to the main square object should be private either private
I am using Rhino Mox
Thanks for any help :)
If you put that functionality File that reads the file such as
FileReader: IFileReader
Then in the form of a Arg in IFileReader Near the manufacturer. Then you can fake it
Comments
Post a Comment