加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

单元测试 – 编辑触发测试是下一步吗?

发布时间:2020-12-13 20:09:53 所属栏目:百科 来源:网络整理
导读:我刚刚阅读了Michael C. Feathers的精彩书籍 Working Effectively with Legacy Code,这是对遗留代码进行测试的圣经.在本书中,他描述了一种称为编辑触发测试的东西: If it isn’t out by the time this book is released,I suspect that someone will soon d
我刚刚阅读了Michael C. Feathers的精彩书籍 Working Effectively with Legacy Code,这是对遗留代码进行测试的圣经.在本书中,他描述了一种称为编辑触发测试的东西:

If it isn’t out by the time this book is released,I suspect that someone will soon develop an IDE that allows you to specify a set of tests that will run at every keystroke. It would be an incredible way of closing the feedback loop.

It has to happen. It just seems inevitable. There are already IDEs that check syntax on each keystroke and change the color of code when there are erros. Edit-triggered testing is the next step.

当我读到这篇文章时,我没有听说过支持这一点的任何IDE或工具.但是,我刚刚发现了一个名为Infinitest的项目,它支持Java.

我的问题是:

>是否有任何其他工具/框架支持此功能(希望也适用于Visual Studio)?
>您对此类测试有何体验(高效,减慢IDE等)?
>这是TDD的下一步吗?

更新:

>看看这个screencast,看看Eclipse中的Infinitest.
>刚刚找到一个博客,Brett Schuchert分享了一些experiences with Infinitest.

ruby有 Autotest.它在编辑文件时不断运行单元测试,使用一些简单的约定将源文件映射到测试文件.还有一个插件,我已经看到,在emacs中以交互方式为测试代码添加红色或绿色.我认为在代码编辑器本身中立即视觉反馈传递/失败的想法非常棒.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读