拼吾爱程序人生.Net编程Visual Studio.NET PartCover: New Open Source Code Coverage Tool

1  /  1  页   1 跳转 查看:895

PartCover: New Open Source Code Coverage Tool

PartCover: New Open Source Code Coverage Tool

Posted by Jay Flowers  From/InfoQ

Last September Peter Waldschmidt, the creator of NCover, made NCover a commercial product. NCover was a free tool and had become a popular choice, especially among open source projects. Gnoso, Peter’s company, has continued to embrace the open source community by providing free licenses to open source projects. This has not been enough for some open source projects. In response PartCover has be receiving increased attention.

PartCover is an open source code coverage tool for .Net very similar to NCover. It includes a console application, GUI coverage browser, and xsl transforms for use in CC.Net.

SharpDevelop, an open source IDE for .NET, has switched to PartCover as of their Beta 1 for version 3.0.
Previously, the addin used NCover for calculating code coverage (this is a metric you gain by writing unit tests). However, recently NCover was turned into a commercial product. Because we only include / support tools that are free to use for anyone (commercial or open source / hobby development), we switched to a different tool - PartCover.
The project leader for TreeSurgeon, Bil Simser, reached out to the community looking for an alternative to NCover.
For the longest time, I've been using NCover for coverage. It was free, gave good results and with NCoverExplorer and CI integration it was the perfect tool. Easy to use, easy to setup, and worth the typical hassle of new tools (setup, learning, configuration, etc.)
NCover has since gone commercial and the old versions won't run properly against 3.0/3.5 code. I'm ditching NCover support in TreeSurgeon because of this. TS nees to be friction free and something anyone can just grab and run and not have to deal with buying or obtaining licenses for products the generated code depends on. I looked at Clover.NET as an alternative (last time I checked it was free?) but it's $600 just for an "academic" version.
So what's with coverage and .NET these days? Are these the only options? Have all the open source/free tools gone the way of the Dodo for coverage and .NET 3.0 projects? My quick Google checks this freezing morning (it was minus 38 as I drove in this morning, that's -36 in Fahrenheit kids) don't show anything.
InfoQ: Will you be switching to PartCover like SharpDevelop 3.0?

Bil Simser: Yes, we’re dropping NCover 1.5.8 support in the next release of Tree Surgeon. If you’re building a 2.0 tree, you’ll get the option to use NCover or PartCover. If you’re building a 3.x version, you only get PartCover.

InfoQ: Have you played with PartCover yet? If so what are your thoughts on it?

Bil Simser: I found it doesn’t have as much “flair” as NCover did and there is no PartCover.Explorer (yet) so hopefully some of those NCover extensions will move to PartCover soon. The tool was easy to get going, but lack of documentation meant I spent most of an afternoon trying out different command line options to get the right result. In the end I think PartCover is a good tool for coverage and .NET projects but it’s young and needs to grow.

InfoQ: Is PartCover Coverage Browser the analog of NCover Explorer?

Bil Simser: It is, but it’s pretty simplistic. Does the job, but needs some improvement in the UI and features.
With attention from TreeSurgeon and SharpDevelop PartCover stand a good chance of filling the void left by NCover’s move to a commercial product.

 感谢原创者的辛勤劳动,希望对您有所帮助,转载请注明原出处。
 您可能对 [Visual Studio.NET] 的这些文章也感兴趣:

.NET 4.0: Type Equivalency (1):NO PIA
依赖注入是否值得?
Windows Mobile 6.0 SDK及开发体验(三:编辑注册表 )
VisualStudio 2010从分析到实施(3)——使用Use Case Diagram设计系统交互
如何让Visual Studio和web标准联姻
.NET Framework 应用架构指南2.0 Beta1发布
体验.net 2.0 的优雅 -- 异步WebService调用
为通过ClickOnce部署的应用程序配置文件类型
微软发布Enterprise Library 4.1和Unity 1.2
.NET加密原理之方法体加密信息对应关系
 

回复: PartCover: New Open Source Code Coverage Tool

PartCover:新的开源代码覆盖工具

译/张逸

去年九月,NCover的创始人Peter Waldschmidt将NCover发展为一个商业产品。NCover原本是一个免费工具,并逐渐得到普及,尤其是在开源项目中。Peter的公司Gnoso通过为开源项目提供免费的许可,继续对开源社区提供支持。这对于某些开源项目而言还远远不够。因此,PartCover得到了越来越多的关注。

与NCover非常相似,PartCover是针对.NET的一个开源代码覆盖工具。它包括了一个控制台应用程序,GUI覆盖浏览器,以及用在CC.NET中的xsl转换。

作为.NET的一个开源IDE,SharpDevelop在3.0版本的Beta 1版本中转为使用了PartCover。

之前,插件使用了NCover来计算代码覆盖率(这是通过编写单元测试可以获得的度量值)。然而,最近NCover已经转变为一个商业产品。由于我们只能包含/支持那些给所有人(用于商业开发或者开源以及出于爱好的开发)免费使用的工具,因此我们转为使用另一个工具——PartCover
TreeSurgeon的项目带头人Bil Simers,通过社区搜寻NCover的替代品。
在很长的一段时间内,我都在使用NCover用于代码覆盖计算。它是免费的,能够获得精准的结果,以及它提供了对NCoverExplorer和CI的集成,使得它成为了一个优秀的工具。易于使用,易于安装,抵消了新工具的特有麻烦(安装,学习,配置等)。
自从NCover商业化后,旧版本不能很好地运行3.0/3.5的代码。我之所以在TreeSurgeon中放弃对NCover的支持,正是因为此。TS从来都是免费的,任何人都可以获得并运行它,而无需为生成代码所依赖的产品购买或获取许可。我看中了Clover.NET作为替代品(在上次我还看见它是免费的?),但即使是它的“学术”版也需要$600。
那么,如今还有什么针对.NET项目的覆盖工具?这些工具是唯一的选择吗?是否所有用于计算.NET 3.0项目代码覆盖率的开源/免费工具都已成为了明日黄花?在这个寒冷的早晨(今早,在我驱车行驶时,温度降到了零下38度,即华氏-36度),我使用Google快速搜索,却得不到任何结果。
InfoQ:你会像SharpDevelop 3.0那样转为使用PartCover吗?

Bil Simers:是的,在Tree Surgeon的下一次发布中,我们会放弃对NCover 1.5.8的支持。如果你构建的是2.0版本的tree,你可以选择使用NCover或者PartCover。如果你构建的是3.x版本的项目,你只能使用PartCover。

InfoQ:你使用过PartCover吗?你对此有何看法?

Bil Simers:我认为它还不能完全与NCover相匹敌,它没有PartCover.Explorer(迄今为止),因此,我希望NCover的某些扩展内容能够很快地移植到PartCover中。这个工具很容易上手,但缺乏文档的支持,这意味着我将花去大半个下午的时间去尝试各种不同的命令行选项以获得正确的结果。最后,我认为PartCover对于.NET项目和代码覆盖而言,是一个不错的工具,但它还很稚嫩,需要不断发展。

InfoQ:PartCover的覆盖浏览器(Coverage Browser)与NCover Explorer相类似吗?

Bil Simers:是的,但它更加简单。它实现了这一功能,但需要对UI和特性进行某些改善。

随着TreeSurgeon和SharpDevelop对PartCover的关注,在NCover转变为商业产品的时候,PartCover有机会填补NCover留下的空白。
 
1  /  1  页   1 跳转

快速回复帖子

标题
禁用 URL 识别
禁用表情
禁用 Discuz!NT 代码
使用个人签名
  [完成后可按 Ctrl+Enter 无刷新发布]  

版权所有 拼吾爱程序人生    

Powered by Discuz!NT 2.1.202   Copyright © 2001-2008 Comsenz Inc. 鄂ICP备07500843号
返顶部