Zany Adventures in Software Engineering with Maven and Motley
design by contract
root cause analysis
Browse by Tags
Tagged Content List
Motley says: "If-then-else hooks are the best way to inject mock objects"
Summary Motley: A simple if-then-else hook is the simplest and best way to inject a mock object. Maven: First, you have to design to interfaces. Then, techniques like dependency injection, factories, and endo-testing are more effective ways to inject mock objects. ______________________________...
14 Aug 2007
Motley says: "The only thing I'm going to mock is you"
Summary Motley: I can't mock something that I have no control over (like third-party or old legacy code) Maven: Design to interfaces, create a wrapper, and use tools for mocking. These are all great practices for leveraging mock objects. ______________________________ [Context: Motley...
7 Aug 2007
Motley says: "Unit tests take too long to execute, so don't bother"
Summary Motley: Unit tests take too long to execute. I'm not going to bother. Maven: Unit tests need to run quickly - you need to execute them frequently. Mock objects can help. ______________________________ [Context: Motley has been writing unit tests for a couple of days, but...
4 Apr 2007
Page 1 of 1 (3 items)
© 2014 Microsoft Corporation.
Privacy & Cookies