请告诉我一个伟大的方式它进行集成测试? [英] Whats a great way to perfom integration testing?

查看:171
本文介绍了请告诉我一个伟大的方式它进行集成测试?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们已经写了自己的集成测试工具,我们可以写一些操作或测试,如GenerateOrders的。我们有多个参数,我们可以使用来配置测试(如订单的数量)。然后,我们写第二次手术,以确认测试已通过/失败(即有(NT)的订单)。

We have written our own integration test harness where we can write a number of "operations" or tests, such as "GenerateOrders". We have a number of parameters we can use to configure the tests (such as the number of orders). We then write a second operation to confirm the test has passed/Failed (i.e. there are(nt) orders).

该工具用于

  • 在集成测试
  • 数据生成
  • 终端到终端的测试(通过混合和匹配多项测试)

这似乎运作良好,但需要开发经验,以保持并写入新的测试。我们的测试团队想动手,谁拥有小C#开发经验。

It seems to work well, however requires development experience to maintain and write new tests. Our test team would like to get involved, who have little C# development experience.

我们只是要开始一个新的新建项目,我做了一些研究,最佳的方式来编写和维护的集成测试。

We are just about to start a new Greenfield project and I am doing some research into the optimum way to write and maintain integration tests.

的问题如下:

  • 如何进行集成测试?
  • 您使用的是什么工具做(健身?自?NUnit的)?

我期待着各国人民的建议/意见。

I am looking forward to peoples suggestions/comments.

在此先感谢,

大卫

推荐答案

集成测试,可以在用户界面层(通过自动化功能测试 - 的 AFT 的)来实现。或者服务/ API接口电平

Integration testing may be done at a user interface level (via automated functional tests - AFT) or service/api interface level.

有两种情况下的几个工具:

There are several tools in both cases:

我已经对项目的工作,成功地使用 SAHI公司的网络应用程序,的AFT为.NET WPF或WinForms的应用程序,的swtBot 为Eclipse富客户端应用程序AFT和怪人对于Java的Swing应用程序的AFT。

I have worked on projects that successfully used Sahi or Selenium for AFT of web apps, white for AFT for .NET WPF or winforms apps, swtBot for AFT of Eclipse Rich client apps and frankenstein for AFT of Java swing apps.

FitNesse的是服务/ API级测试或运行只是用户界面下方的测试非常有用。如果使用得当,它有业务可读的测试,即非开发人员能够阅读和理解测试的优势。像NUnit的工具是用于此目的的那么有用。 SOAPUI 是特别适合于测试SOAP网络服务。

Fitnesse is useful for service/api level tests or for tests that run just below the UI. When done right, it has the advantage of having business-readable tests i.e. non-developers can read and understand the tests. Tools like NUnit are less useful for this purpose. SOAPUI is particularly suited for testing SOAP web services.

要考虑的因素:

  • 时间:你可以忍受8小时试运行
  • 脆性:AFTS可针对不断变化的应用程序非常脆弱(如小部件的ID和位置可能会改变)。充足的技术和努力,需要到C发生变化的部分不难$ C $。
  • 富达:如何接近现实世界,你希望它是什么?例如您可能需要模拟出相互作用支付网关,除非供应商为您提供了一个测试环境,您可以与你的测试揍。
  • Duration: Can you tolerate 8 hour test runs?
  • Brittleness: AFTs can be quite brittle against an evolving application (e.g. ids and positions of widgets may change). Adequate skill and effort is needed to not hard code the changing parts.
  • Fidelity: How close to real world do you want it to be? e.g. You may have to mock out interactions with a payment gateway unless the provider provides you a test environment that you can pummel with your tests.

有些细微差别被捕获这里

Some nuances are captured here.

全面披露:作者是有幕后组织相关的最上面的自由和开放源码工具(不是全部)

Full disclosure: The author is associated with the organization behind most (not all) of the above free and open source tools.

这篇关于请告诉我一个伟大的方式它进行集成测试?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆