I have a method that calls two other methods in it. def main_method(self, query): result = self.method_one(query)
I\'m readin http://xunitpatterns.com/Test%20Stub.html and have some questions开发者_开发知识库 about the use of stubs, for example, in the code shown on the page the author creates a class called Time
We use hand written stubs in our unit tests and I\'m exploring the need for a Mock framework like EasyMock or Mockito in our p开发者_高级运维roject.
Are there any circumstances where it is favourable to manually create a stub type, as opposed to using a mocking framework (such as Rhino Mocks) at the point of test.
I just watched this funny YouTube Video about unit testing (it\'s Hitler with fake subtitles chewing out his team for not doing good unit tests--skip it if you\'re humor impaired) where stubs get roun