WatiN 支持重定向吗?
我正在尝试自动化与 WatiN 集成库中链接的测试。
// url like "https://api.linkedin.com/uas/oauth/authorize?oauth_token=ba826cd4-644a-4709-b2de-bedb7c8fb5b4"
using (var ie = new IE(authorizationUrl))
{
if (ie.TextField("email-oauthAuthorizeForm").Exists
&& ie.TextField("password-oauthAuthorizeForm").Exists)
{
ie.TextField("email-oauthAuthorizeForm").Value = "some@mail.com";
ie.TextField("password-oauthAuthorizeForm").Value = "password";
ie.Button(Find.ByName("authorize")).Click();
//ie.Forms[0].Submit();
}
}
按下按钮,Internet Explorer 立即重定向到同一页面。表单提交具有相同的行为。
你怎么想的?那是WatiN问题还是linkedin守卫?