1
this weekend I read about the Mockito
and double tests, and I came up with the following idea. Test private methods with this framework.
I saw that the PowerMock
performs such a procedure, but someone has already tried to do so using the Mockito
with reflection
?
In this discussion I would also like to know from friends the opinion about testing or not private methods, I saw some discussions on this in SO.com
and I was in doubt, because when I declare a private method only segment for each method a responsibility and not put several things in the same method.
Thank you
I believe that it is not necessary to test private methods, as they exist as an aid to the public. Testing public methods should be sufficient.
– user7261