selenium-grid

Setting up Selenium Grid

こ雲淡風輕ζ 提交于 2019-12-01 08:16:13
I am setting up Selenium Grid server and I have done successfully on my local machine and I'm wondering how to give the hostname so if other tester wants to register to the hub they should be able to do that, here is what I have done so far: on my local machine (assuming I will be allowing other tester to register the node here) Starting a Hub on my local machine: java -jar selenium-server-standalone-2.21.0.jar -hub Starting a Node java -jar selenium-server-standalone-2.21.0.jar -role node -hub localhost:4444/grid/register I view the status of the hub: localhost:4444/grid/console Now, my

Chrome on remote webdriver (via Grid) failed to start

故事扮演 提交于 2019-12-01 06:43:20
I'm having trouble launching Cucumber test with Chrome using remote webdriver capabilities on Grid (1 linux hub and 1 linux node with Firefox and Chrome). Firefox test go very well but Chrome returns the following error: unknown error: Chrome failed to start: exited abnormally (Driver info: chromedriver=2.2,platform=Linux 3.2.0-23-generic-pae x86) (WARNING: The server did not provide any stacktrace information) java.util.concurrent.ExecutionException: org.openqa.selenium.WebDriverException: java.lang.reflect.InvocationTargetException Command duration or timeout: 20.67 seconds Build info:

Chrome on remote webdriver (via Grid) failed to start

吃可爱长大的小学妹 提交于 2019-12-01 04:46:53
问题 I'm having trouble launching Cucumber test with Chrome using remote webdriver capabilities on Grid (1 linux hub and 1 linux node with Firefox and Chrome). Firefox test go very well but Chrome returns the following error: unknown error: Chrome failed to start: exited abnormally (Driver info: chromedriver=2.2,platform=Linux 3.2.0-23-generic-pae x86) (WARNING: The server did not provide any stacktrace information) java.util.concurrent.ExecutionException: org.openqa.selenium.WebDriverException:

Error forwarding the new session: Selenium Grid 2

与世无争的帅哥 提交于 2019-12-01 01:20:16
I have taken latest Selenium Server which is 2.45.0 from here . Followed the documentation and started the hub with the following command java -jar selenium-server-standalone-2.45.0.jar -role hub -hubConfig HubConfigFile.json And, the JSon file content is: { "host": 10.5.0.21, "port": 4444, "newSessionWaitTimeout": -1, "servlets" : [], "prioritizer": null, "capabilityMatcher": "org.openqa.grid.internal.utils.DefaultCapabilityMatcher", "throwOnCapabilityNotPresent": true, "nodePolling": 5000, "cleanUpCycle": 5000, "timeout": 300000, "browserTimeout": 0, "maxSession": 5, "jettyMaxThreads":-1 }

Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms. with FF version 26.0 and selenium standalone jar 2.39

荒凉一梦 提交于 2019-12-01 01:11:58
问题 I am trying to connect to selenium 2.30 with FF version 26.0 installed in my AWS unix machine but I am getting below error when I start both my client which access selenium. Also, when I try the same with selenium standalone jar 2.38.0, it works fine but suddenely after some time in a day or two, it starts giving below error with 2.38.0 as well. Not sure why this is happening? Any idea?? project is I have a multithreadin app wherein client keeps executing some threads which pings some URLS

RemoteWebDriver and Grid - is it possible to get the server ip?

ぐ巨炮叔叔 提交于 2019-11-30 22:05:39
I am using RemoteWebDriver from Selenium 2 and Grid to divide my tests on several virtual machines. Let's say I have two Linux machines and in a test I specify the capabilities to run on a Linux machine, I can't figure out which of these two machines is being used. Is there any way, to figure it out? Something like driver.getServerIp() or anything else? The reason is, in my Selenium test code I want to start a bash script on the console of the linux machine where the test is being run. Therefore I have to know on which machine the test runs. Thanks guys! My java skills aren't the greatest and

Remote WebDriver UnreachableBrowserException: Could not start a new session

删除回忆录丶 提交于 2019-11-30 09:50:14
问题 I got this exception for all browsers. For example, I create a remote webdriver on chrome like this: caps = DesiredCapabilities.chrome(); ChromeOptions options = new ChromeOptions(); options.addArguments("disable-infobars"); caps.setCapability(ChromeOptions.CAPABILITY, options); webDriver = new RemoteWebDriver(new URL("http://myIP:5555/wd/hub"), caps); And I got UnreachableBrowserException as follow: org.openqa.selenium.remote.DesiredCapabilities chrome INFO: Using `new ChromeOptions()` is

UnreachableBrowserException: Could not start a new session. Possible causes are invalid address of the remote server with Selenium Grid

会有一股神秘感。 提交于 2019-11-30 07:47:58
问题 Error in opening new driver window: org.openqa.selenium.remote.UnreachableBrowserException: Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure. server log: Forwarding newSession on session null to remote I am running following code on linux: driver= new RemoteWebDriver((new URL( "http://"+ip+":5555/wd/hub")), capability); My hub-node already up and running. Then why i am getting this error. 回答1: This error message... org.openqa

Selenium 2 Grid - Knowing which node your test is using

空扰寡人 提交于 2019-11-30 06:51:28
Is it possible to know which node the selenium grid hub assigned to your test? My tests need to talk to other services on the node machine in order to perform configurations which are not supported by selenium. Mark Generally you shouldn't rely on knowing what machine your test is running on. Grid 2 provides a series of callback listeners that you could implement to provide machine configuration. But, if you really want to see what node a test is running on, you could use one of the API calls. Both endpoints can be found on the hub: http://localhost:4444/grid/api/proxy http://localhost:4444

How to execute cucumber test cases in parallel using Grid?

天涯浪子 提交于 2019-11-30 05:42:34
问题 After doing a fair amount of research on how to run Cucumber test cases in parallel, I found the following very useful article on the subject matter: https://www.opencredo.com/2013/07/02/running-cucumber-jvm-tests-in-parallel/ The article has some pretty good information to get you started working with a multi-threaded environment, including some code you can download from Github. https://github.com/tristanmccarthy/Cucumber-JVM-Parallel If I understand the article correctly the driver should