集成测试
我正在 .net 中进行开发并使用 NUnit。 我对不同的课程和每个不同的模块进行了测试。
我现在需要的是一起测试所有模块! 这些模块通过 DB 和 Tibco 基础设施相互联系。
我应该如何一起测试所有这些交响乐?
PS - 如果有比 NUnit 更有用的东西,我愿意接受建议。
I'm developing in .net and using NUnit.
I have tests for different classes and for each of the different modules.
What I need now is to test all the modules together!
the modules contact each other via DB and Tibco infrustructure.
How should I test all this symphony together ?
P.S. - if there's something more useful for this case than NUnit i'm open to suggestions.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果类直接相互调用,那么编写集成测试将很容易 - 只需调用顶级类而不提供任何模拟。在您的情况下,您可能能够:
我不这样做看到使用 NUnit 作为此测试的运行程序的问题。我的建议是将测试标记为显式,这样它就不会作为常规构建或测试运行的一部分运行。
If the classes called each other directly, it would be easy to write an integration test - simply call the top-level class without providing any mocks. In your case, you might be able to:
I don't see a problem with using NUnit as the runner for this test. My suggestion would be to mark the test as Explicit so it does not run as part of a regular build or test run.
我认为你不应该进行集成测试。
基本正确性的单元测试和客户/产品所有者的验收测试。
不过,如果您可以在 NUnit 中制定验收测试,我认为那就很好了。我建议您阅读此。这是很有意见的,但我同意。
对于验收测试,有一些工具(例如:cucumber 和 specflow),但它们都依赖于与客户的沟通。
In my opinion you should not integration test.
Unit test for basic correctness and acceptance test for the customer/product owner.
If however you can formulate an acceptance test in NUnit that is fine I think. I suggest you read this. It is very opinoinated, but I agree.
For acceptance testing there are tools (for instance: cucumber and specflow), but they all depend on communication with the customer.