什么单元测试框架可以满足我的要求?
这就是我在高层次上寻找的一切:
- 在 Visual Studio 2008 中运行单元测试的能力
- 与某些代码覆盖工具的兼容性
- 具有行测试功能(如 MBUnit 的 RowTestAttribute
- 能够与 Team City
我以为我已经在 xUnit.net 1.8、resharper 6.0 和 dotCover 1.1.1 中找到了这个。然而,在花了将近一天的时间摆弄这些东西之后,我发现了这个设置的这些主要问题:
- Resharper 中不完全支持理论测试(行测试) - 更多信息
- dotCover 基本上不适用于 xUnit
我已成功使用 MSTest ReSharper 可以做我需要的一切,除了行测试,但似乎生活可以使用一些更先进的测试框架会更好。
我已经开始关注 Gallio,但我希望有人可以节省我一些时间并推荐一款获胜的游戏在我浪费更多时间探索之前组合。
您成功使用过哪种组合?
This is all i'm looking for at a high level:
- The ability to run unit tests from within visual studio 2008
- Compatibility with some code coverage tool
- A unit testing framework with a row testing feature like MBUnit's RowTestAttribute
- Ability to integrate with Team City
I thought i had found this with xUnit.net 1.8, resharper 6.0, and dotCover 1.1.1. However, after investing almost a day with messing around with this stuff i've found these major issues with this setup:
- Theory tests (row tests) are not fully supported in Resharper - more info
- dotCover basically does not work with xUnit
I was successfully using MSTest with ReSharper to do everything i need but the row tests, but it seems that life could be much better with some of the more advanced testing frameworks.
I've started looking at Gallio, but I'm hoping that someone can save me some time and recommend a winning combination before I waste any more time exploring.
What combination have you used successfully?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我建议您使用
NUnit
:TestDriven.NET
或ReSharper
与 Visual StudioPartCover
code>、Sonar
、NCover 1.5.8 free
作为代码覆盖工具TestCase
属性来传递不同的参数集(ReSharper 完美支持此属性)团队城市
支持内置于TestCase 属性的示例中
I would suggest you to use
NUnit
:TestDriven.NET
orReSharper
to have full integration with Visual StudioPartCover
,Sonar
,NCover 1.5.8 free
as code coverage toolTestCase
attribute to pass different set of parameters (ReSharper supports this attribute perfectly)Team City
support is built inAn example for TestCase attribute
我强烈建议xUnit.net
请阅读为什么构建它 和 xUnit.net 与其他 .NET 测试框架相比如何。
I strongly suggest xUnit.net
Please read why it was built and how does xUnit.net compare to other .NET testing frameworks.