简体   繁体   English

编码的UI和测试Web应用程序的旧方法

[英]Coded UI and the old ways to test web app

My project used to use Microsoft.mshtml and SHDocVw.dll to automate our Web UI test. 我的项目过去使用Microsoft.mshtml和SHDocVw.dll来自动化我们的Web UI测试。 Then I heard about the CodedUI test. 然后我听说了CodedUI测试。 So questions are: 所以问题是:

  • Does it mean I can give away Microsoft.mshtml and SHDocVw.dll? 这是否意味着我可以放弃Microsoft.mshtml和SHDocVw.dll?
  • And is there any connection/difference between CodedUI and Microsoft.mshtml and SHDocVw.dll? 在CodedUI与Microsoft.mshtml和SHDocVw.dll之间是否存在连接/差异?

Thanks! 谢谢!

Does your existing automation tool have an application with a browser inside it? 您现有的自动化工具中是否包含带有浏览器的应用程序? That is how I've seen SHDocVw.dll used before. 这就是我以前看到过的SHDocVw.dll的方式。 The tests would be able to interact with the web pages' DOM and a lot can be accomplished that way. 这些测试将能够与网页的DOM进行交互,并且可以通过这种方式完成很多工作。 You are, of course, limited to IE, which I believe is also the case with Coded UI. 当然,您仅限于IE,我相信编码UI也是如此。

Coded UI is able to test applications and IE, as I recall. 我记得,编码的UI能够测试应用程序和IE。 So you should be able to use Coded UI to test against your old test app, but it wouldn't really make sense. 因此,您应该能够使用编码UI对旧的测试应用程序进行测试,但这实际上没有任何意义。

Unfortunately, I think you will lose your existing test code if you move to Coded UI, but you will have a larger community to run ideas by, etc. 不幸的是,我认为如果移至“编码的用户界面”,您将丢失现有的测试代码,但是您将拥有更大的社区来运行想法等。

I don't think Coded UI uses SHDocVw.dll, because it interacts with the IE itself, not a form that has a 'browser control' inside it. 我不认为编码UI使用SHDocVw.dll,因为它与IE本身进行交互,而不是与其中具有“浏览器控件”的表单进行交互。

If you don't need cross browser coverage and you don't mind rewriting your existing tests, then CodedUI would be a good choice, in my opinion, to get away from a custom solution. 如果您不需要跨浏览器,并且不介意重写现有测试,那么我认为CodedUI是摆脱定制解决方案的好选择。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM