我可以使用 HP 的 Quick Test Professional 测试 mxGraph ui 吗?
您好,
是否可以使用 Quick Test Professional 通过 UI 测试 mxGraph?
Hy,
Is it possible to test mxGraphs via UI by using Quick Test Professional?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
假设您将 mxGraphs(下次有链接就好)作为在网络浏览器中绘制图表的 javascript 库:
使用 示例 应用:有可能,但效果很差。左侧的所有基本形状都是可选的,并且通过其“alt”属性或“filename”属性具有唯一的名称。顶部的按钮可以被 QTP 识别,但会导致对象名称的通用创建,如果您想使用,则必须摆弄 Class 属性。
录音示例(关于荷兰文化):
画布(绘图区域)是一个不同的故事。拖放不容易实现自动化,因为它本身无法识别。您必须为此编写自己的函数。
形状识别仅适用于innerHtml 中的属性或x 和y 位置。如果您想要对对象进行广泛的创建和更改/编辑,那么您可以创建一个库,将所有对象作为虚拟对象保存在其中,并记住每个对象的状态。但这并不容易。
在 WinXP SP3、IE8 和 QTP10.00 上测试过
TL;DR 否。有些组件可以通过 QTP 捕获,但会很烦人和缓慢。只有当您只想查看侧边栏上的所有项目是否都存在并且可以创建时,才值得付出努力。
Assuming you mean mxGraphs (a link would be nice next time) as javascript library for drawing diagrams in the webbrowser:
Using the example application: It is possible, but poorly. All basic shapes on the left side are selectable and have unique names by their "alt" property or "filename" property. The buttons on top are recognizable by QTP, but results in generic creation of object names, you'll have to fiddle with the Class attributes if you want to use the,.
Recording example (on dutch culture):
The canvas (drawing area) is a different story. Drag and Drop is not easily automatable because it is not recognized nativly. You have to write your own functions for that.
Shape recognition is only doable on properties in the innerHtml, or the x and y locations. If you want to do extensive creation and changing/editing of objects, then you could create a library with all objects kept in it as sort of virtual objects, remembering the state of each objects. But is won't be easy.
Tested on WinXP SP3, IE8 and QTP10.00
TL;DR No. Some components can be captured by QTP, but it will be tiresome and slow. It will only be worth the effort if you only want to see if all items on the side-bar are present and can be created.
这是可行的。我们实现类似目标的方法是确保您拥有固定大小和固定分辨率的窗口。为了检查结果,我们只是对预期内容进行了二进制比较,并进行了屏幕截图(全屏使用浏览器)。
不是最好的解决方案 - 但大部分时间都有效。
It is doable. The way that we achieve something similar was to ensure that you have the window of the a fixed size and of fixed resolution. To check the results we just did a binary diff on what was expected and a screen shot (used the browser at full screen).
Not the best solution - but kinda worked most of the time.