几天以来,我一直在从事硒网格研究。我已经在同一台机器上为Android创建了集线器和节点。节点正在集线器上注册,执行也开始。但是一段时间后,会话失败,执行停止。几乎没有2-3个测试用例被执行。
请检查下面的错误日志以供参考
[testng] [WebDriverCommandLogger] - Executing findElements parameters: {"using":"css selector","value":".spinner-backdrop"}
[testng] [WebDriverCommandLogger] - command: findElements[ param-1: {value=.spinner-backdrop, using=css selector}] Result: [id: 0.5843276489161311-137]
[testng] [WebDriverCommandLogger] - Executing findElements parameters: {"using":"css selector","value":".spinner-backdrop"}
[testng] [WebDriverCommandLogger] - command: findElements[ param-1: {value=.spinner-backdrop, using=css selector}] Result: []
[testng] [WebDriverCommandLogger] - Executing findElements parameters: {"using":"css selector","value":".centered-middle"}
[testng] [WebDriverCommandLogger] - command: findElements[ param-1: {value=.centered-middle, using=css selector}] Result: []
[testng] [WebDriverCommandLogger] - Executing actions parameters: {"actions":[{}]}
[testng] [WebDriverCommandLogger] - command: actions[ param-1: {actions=[org.openqa.selenium.interactions.Sequence@7f6f288]}] Result: actions
[testng] Build info: version: '3.14.0', revision: 'aacccce0', time: '2018-08-02T20:19:58.91Z'
[testng] System info: host: 'hostname', ip: 'ipaddress', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_171'
[testng] Driver info: driver.version: RemoteWebDriver
[testng] [WebDriverCommandLogger] - Executing screenshot parameters: {}
[testng] [WebDriverCommandLogger] - command: screenshot[ param-1: {}] Result: Session [c9e02a30-4c4d-4181-a588-7072b4372a90] was terminated due to FORWARDING_TO_NODE_FAILED
[testng] Command duration or timeout: 0 milliseconds
[testng] [WebDriverCommandLogger] - Executing screenshot parameters: {}
[testng] [WebDriverCommandLogger] - command: screenshot[ param-1: {}] Result: Session [c9e02a30-4c4d-4181-a588-7072b4372a90] was terminated due to FORWARDING_TO_NODE_FAILED
答案 0 :(得分:0)
传递参数-e ZALENIUM_EXTRA_JVM_PARAMS =“-Dwebdriver.http.factory = apache”,如下所示:
docker run --rm -t --name zalenium -p 4444:4444 -e ZALENIUM_EXTRA_JVM_PARAMS =“-Dwebdriver.http.factory = apache” -v /var/run/docker.sock:/var/run/docker .sock ...
它已经解决,并在这里进行了讨论: https://github.com/zalando/zalenium/issues/593