请求失败:在测试上下文中找不到上下文参数“RequestVerificationToken” [英] Request Failed: Context parameter 'RequestVerificationToken' not found in test context
问题描述
获取请求失败:在录制后尝试运行webtest时,在测试上下文
中找不到上下文参数'RequestVerificationToken'错误。该应用程序是.net上的内部Web应用程序。
Getting Request Failed: Context parameter 'RequestVerificationToken' not found in test context
error when trying to run a webtest after recording. The application is an internal web application on .net.
尝试将令牌保存在变量中,然后在Form Post Parameters中使用它但没有解决问题。
Tried to save the token in a variable and then using it in Form Post Parameters but didnt solved the issue.
任何指针都会有所帮助。
Any pointers will be helpful.
推荐答案
您好Adi1989,
Hi Adi1989,
>> 请求失败:在测试环境中找不到上下文参数'RequestVerificationToken'
错误。
>>Request Failed: Context parameter 'RequestVerificationToken' not found in test context error.
通常我们需要检查上一个请求:
Generally we need to check the previous request:
HTTPS://social.msdn .microsoft.com /论坛/ EN-US / bb1f365e-d430-4b64-AE25-a55a40b22b04 /上下文参数hidden1eventtarget未找到,在测试上下文错误 - 在-VS-2010-负荷?论坛= vstswebtest
我建议您在网页请求中添加规则:
I suggest you add the rule in your web request:
注意:此响应包含对第三方万维网站点的引用。 Microsoft提供此信息是为了方便您。
Microsoft不控制这些网站,也未测试在这些网站上找到的任何软件或信息;
因此,Microsoft无法就任何质量,安全性或适用性做出任何陈述在那里找到的软件或信息。
在使用任何软件时存在固有的危险在互联网上,微软提醒您在从互联网上检索任何软件之前确保完全理解风险。
最好的问候,
杰克
这篇关于请求失败:在测试上下文中找不到上下文参数“RequestVerificationToken”的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!