- UID
- 110742
- 热情
- 18
- 人气
- 95
- 主题
- 0
- 帖子
- 297
- 精华
- 0
- 积分
- 216
- 分享
- 0
- 记录
- 0
- 相册
- 0
- 好友
- 0
- 日志
- 0
- 在线时间
- 917 小时
- 注册时间
- 2007-3-11
- 阅读权限
- 20
- 最后登录
- 2012-7-17
升级 5.33% - UID
- 110742
- 热情
- 18
- 人气
- 95
- 主题
- 0
- 帖子
- 297
- 精华
- 0
- 积分
- 216
- 阅读权限
- 20
- 注册时间
- 2007-3-11
|
原帖由 ybbest 于 2009-7-26 23:38 发表
Real benefits are that you are using code to document code in terms of tests and you make sure you understand what is required before writing code.If you do not see these as benefits then I can not c ...
Thanks for your comments about TDD's benefits. It is quite helpful to get your options.
For the same thing, it is quite normal that different person get different idea. Finally, I just address my experience of TDD with a little more details:
1) I do follow the test-first code order at most of time, and do try code-first order as well (my first question is to find out why/whether the order is important), but no significant difference has been found so far, both way get the benefits you mentioned, and others like better spec/implementation isolation and etc, so I do not think coding order important, I believe these benefits comes from unit tests; In fact, both coding order is fine to me. The test-friendly code is different from implementation-only code anyway, as long as I know unit test have to be there, I will not implement in a way to be hard testing. It ensure quality, but double my development time, this is the reason PM say ignore it.
2) I found if make test concern driving design concern totally, the design process will be very different from the traditional approach, and I felt uncomfortable - more precisely, unsure what side-effects will be, not like top-down / bottom-up, we know them so well, both of good sides & bad sides, but Test driven design is not what I am confident with, it is new and strange.
Oops, it is very night, c u later and very happy to get so much useful share knowledge, we could have some meetings for these tech discussion.
[ 本帖最后由 newmike 于 2009-7-27 00:24 编辑 ] |
|