[英]Why does upgrading chome and chrome driver stop web application from loading
Im Running E2E testing on a web application in Jenkins using a centos node with webdriver IO.我使用带有 webdriver IO 的 centos 节点在 Jenkins 中的 Web 应用程序上运行 E2E 测试。
Chrome:google-chrome-stable-96.0.4664.110-1.x86_64.rpm Chrome driver: Chrome:google-chrome-stable-96.0.4664.110-1.x86_64.rpm Chrome 驱动程序:
sh 'sudo yum info google-chrome-stable | grep Version > chromeOutFile'
def CHROME_VERSION = readFile('chromeOutFile')
def Version = CHROME_VERSION.split('Version :')
def VersionNumber = Version[1].trim()
sh "./src/main/web/node_modules/protractor/bin/webdriver-manager update --versions.chrome=${VersionNumber}"
Id like to update this to user the latest version of chrome with a corresponding chrome driver.我想更新这个给用户最新版本的 chrome 和相应的 chrome 驱动程序。
Webdriver IO config: Webdriver IO 配置:
services: [['chromedriver', {
chromedriverCustomPath: '../node_modules/webdriver-manager/selenium/chromedriver_96.0.4664.110'
}]],
Problem: when I try to use a more upto date version, even if its chromedriver_97.0.4692.99, my web application no longer starts up in Jenkins.问题:当我尝试使用更新版本时,即使它是 chromedriver_97.0.4692.99,我的 Web 应用程序也不再在 Jenkins 中启动。 When I try to visit the url, the screen shot just shows a blank screen.
当我尝试访问 url 时,屏幕截图只显示一个空白屏幕。 Im not sure the application is even loading.
我不确定应用程序是否正在加载。
Why does it only work with 96 but not others?为什么它只适用于 96 而不是其他?
I tried to map the version of chrome with an appropriate version of chrome driver using https://chromedriver.storage.googleapis.com/LATEST_RELEASE_97.0.4692 but that still doesnt work for me.我尝试使用https://chromedriver.storage.googleapis.com/LATEST_RELEASE_97.0.4692将 chrome 版本与适当版本的 chrome 驱动程序映射,但这对我来说仍然不起作用。
Running tests:运行测试:
cd e2e && wdio run wdio.ci.conf.ts --suite access --logLevel=info
+ lsb_release -d
Description: CentOS Linux release 7.9.2009 (Core)
Thanks谢谢
Have you tried to check memory limits?您是否尝试检查内存限制? I had a similar problem with automated testing and had to change memory limits to either 1) limit chrome's memory or 2) pre allocate a set amount of memory ahead of time from my webserver if you are testing on the same device.
我在自动测试中遇到了类似的问题,必须将内存限制更改为 1) 限制 chrome 的内存或 2) 如果您在同一台设备上进行测试,请提前从我的网络服务器预分配一定数量的内存。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.