为什么我的基类的构造函数被击中两次,而我的编码UI测试却运行两次? [英] Why does the constructor of my base class get hit twice and my coded UI test run twice?

查看:93
本文介绍了为什么我的基类的构造函数被击中两次,而我的编码UI测试却运行两次?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有3个班级:

ActionBase,Smoke(从ActionBase继承)和SinoTests(从Smoke继承). SinoTests类具有[CodedUITest]属性,其他是普通类.

ActionBase, Smoke (which inherites from ActionBase), and SinoTests (which inherits from Smoke).  SinoTests class has the [CodedUITest] attribute, the others are plain classes.

运行测试时,由于某种原因,它会运行两次.另外,ActionBase的构造函数被击中两次.我不明白为什么要这么做.

When I run my test, it gets run twice for some reason.  Also, the constructor of ActionBase is hit twice.  I don't understand why it's doing this.

感谢您的帮助!

closl

推荐答案

Hi Closl,

Hi Closl,

为了重现您的情况并彻底发行,请您向我们分享一个完整的样本,可以用来在我们这边重现您的问题?如果可能,请附加它,并将其上传到OneDrive: https://onedrive.live.com/,然后在此处发布下载链接.我们将在我们这方面进行研究.

In order to repro your scenario and issue completely, could you please share us a complete sample which can be used to repro your issue on our side? If possible, please attach it, upload it to OneDrive: https://onedrive.live.com/ and then post the download link here. We will research it on our side.

最好的问候


这篇关于为什么我的基类的构造函数被击中两次,而我的编码UI测试却运行两次?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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