开发者

Is Test coverage going down with JRebel?

it's good practice to write Unittests to

  • be independed of the whole spring application context
  • automate the test you are doing for continuous integration
  • avoid dependency on the Servlet Container

I guess with JRebel there's a temptation to test everything in the running application and 'forget' to write Unittests. What's your exp开发者_StackOverflow中文版erience?


I like to think that you're not writing unit tests because of the slow turnaround cycle but for other reasons. The moment the turnaround cycle goes to zero there is still benefits of unit tests.


I think that would be a big mistake. Sure it is faster, but you have no assurance that you aren't breaking things.

So it is faster to do manual unit testing, but the disadvantages aren't just about speed. You can't retest everything on every change without automated tests.

JRebel does make in-container unit tests more viable, though.


I tend to think that writing and running unit tests is a good way to compile the appropriate classes so that JRebel can reload them.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜