From: Clemmons, S. <sco...@fn...> - 2002-02-25 14:24:47
|
> painful. In this case, do you find that the internal dependencies in your mocks suggest > possible refactorings in your production code? Does the maintenance I think you might be right about this. Either that, or it's just that the code that I've been writing tests for so far have been the entry-points (the primary interfaces) to various subsystems. That is, the calls are typically at a higher level and so have several cross-subsystem dependencies. It's something I need to take a look at. > Next question, do you find that the generated mocks are OK? > Would you be better doing it by hand? Yes & no. I was able to generate ~ a hundered mock classes with mockmaker within a very short time. It would've taken me much much longer without the tool. However, I've found that I often have to customize the generated mock classes slightly in order to be more useful with my tests. Therefore, if the interface changes, and I have to regenerate a mock class, it may be painful. I suspect, though, that most changes would be minor (adding or changing a method or 2), and I can simply make modifications by hand. I'm trying to minimize the effects of changes by this mock framework I've created (somewhat as a facade). Thanks for you comments, Scott |