手动编码的UI测试,导航到不同的URL [英] Manual Coded UI test, navigating to a different URL

查看:102
本文介绍了手动编码的UI测试,导航到不同的URL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前正在自动对IP地址XXX.XXX.XXX.XXX进行一些测试,在我的代码的某个部分我导航到另一个在我开始测试的同一测试浏览器中的URL。我使用的代码如下:

I'm currently automating the some tests on IP address XXX.XXX.XXX.XXX, in a certain part of my code i navigate to a different URL in the same test browser as i started the test in. he code i use is a follows:

 

UITVLicensingThankyouMWindowvar.NavigateToUrl(

UITVLicensingThankyouMWindowvar.NavigateToUrl(

继续测试>>>>>> >(mouse.click..etc)

上述代码执行时有15-20秒的暂停,这是正常的吗?

 

推荐答案

当您导航到另一个Url时,我们会等到页面完全加载,即导航完成,没有ajax请求挂起响应,计时器已过期等。我可以找出等待日志的确切原因。

When you navigate to a different Url, we wait until the page is loaded completely i.e navigation is complete, no ajax requests pending response, timers expired etc. I can figure out the exact reason for the wait only with the logs.

在IE8中,如果您从Internet导航到Intranet,反之亦然,则会有一个受保护的模式更改(取决于您的IE设置)。在这种情况下,IE会重新创建文档窗口,所以我们必须重新获取它。

In IE8, if you navigate from Internet to Intranet or vice versa, there is a protected mode change(depends on your IE settings). In this case, IE re-creates the document window, so we have to refetch it.

希望这会有所帮助。

Vin oth

 


这篇关于手动编码的UI测试,导航到不同的URL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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