简体   繁体   English

Jmeter WebDriver采样器导致'未知协议:数据'

[英]Jmeter WebDriver Sampler resulting in 'unknown protocol: data'

I am currently trying to put load on HTTPS website by using Webdriver Sampler in Jmeter. 我目前正试图通过在Jmeter中使用Webdriver Sampler来加载HTTPS网站。 Jmeter successfully runs the whole Selenium code in Webdriver Sampler; Jmeter成功运行Webdriver Sampler中的整个Selenium代码; but in the end, marks the sampler as Failed in 'View Results Tree' listener. 但最后,在“查看结果树”监听器中将采样器标记为“ 失败 ”。 Response data > Response Body shows 响应数据>响应正文显示

java.net.MalformedURLException: unknown protocol: data java.net.MalformedURLException:未知协议:数据

It's strange, as it already has executed the whole code successfully with even closing the browser. 这很奇怪,因为即使关闭浏览器,它已经成功执行了整个代码。 What's the point of giving this error in the end? 最终给出这个错误的重点是什么?

What is the way out to avoid this failure? 避免这种失败的方法是什么?

The error means that you open the browser and don't call WebDriver.get() function 该错误意味着您打开浏览器并且不调用WebDriver.get()函数

Please inspect all your WebDriver Samplers and ensure that there is the following call in each of them: 请检查所有WebDriver采样器,并确保每个采样器都有以下呼叫:

WDS.browser.get('https://example.com')

replace example.com with the URL of the application you're testing. example.com替换为您正在测试的应用程序的URL。

Check out The WebDriver Sampler: Your Top 10 Questions Answered article for more information on Selenium scripting in JMeter, troubleshooting, tips and tricks. 查看WebDriver采样器:您回答的十大问题文章,了解有关JMeter中Selenium脚本编写的更多信息,故障排除,提示和技巧。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM