We were talking about whether to test or not private methods, making them public to do the tests. I recommend this post of Michael Feathers.
I also recommend the "Mock" testing technique to avoid doing surgery on you objects. Using fake objects to record what methods are call on this object and then trigger the mock.assert() on this object.
No comments:
Post a Comment