问题描述
所以我有一个我继承的应用程序,我想在它周围建立一个自动测试套件。应用程序没有考虑到可测试性,代码是一个大泥球。我的计划是使用UI自动化测试框架,并在UI级别创建一套测试,直到我有足够的覆盖,以允许我开始重构有信心,并在代码中引入一些接缝,以提高可测试性和设计。
这是一个.Net WinForms应用程序,我知道的两个框架是:
和
从我试图作为自动构建(连续集成)的一部分运行时,由于大多数CI产品作为Windows服务运行的事实,如果UI使用模态对话框,应用程序将死亡一个可怕的死亡,这两个框架提出问题。我使用CruiseControl.Net作为我的CI工具。
有人有任何建议来解决这个问题吗?
感谢,
Dylan
NUnitForms有一个隐藏桌面功能,将允许您从cc.net运行单元测试。
So I have an application that I inherited and I want to build up an automated test suite around it. The application wasn't designed with testability in mind, and the code is a "big ball of mud". My plan was to use a UI Automation testing framework and create a suite of tests at the UI level until I had enough coverage to allow me to start refactoring with confidence and introducing some seams into the code to improve testability and design.
It's a .Net WinForms application, and the two frameworks I'm aware of are:
and
From what I've read both frameworks pose issues when trying to run as part of an automated build (Continuous Integration) due to the fact that most CI products run as a Windows Service and if the UI uses modal dialogs the application will die a horrible death. I'm using CruiseControl.Net as my CI tool.
Does anybody have any suggestions to work around this issue? An alternative framework to use that may make the situation better?
Thanks,
Dylan
NUnitForms has a "hidden desktop" feature that will let you run unit tests from cc.net.
http://automaticchainsaw.blogspot.com/2007/09/winforms-testing-using-nunitforms.htmlhttp://automaticchainsaw.blogspot.com/2007/09/hidden-desktops-and-nunitforms.html
这篇关于UI测试框架+持续集成?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!