1

I am new to selenium. I wrote 4 tests, now i want to run 2 tests on one node and two to other, how to do that. both the node have same configurations i mean same browser same platform and same versions i am using selenium-server-standalone-2.44.0.jar to create hub and node.

Alpana Chauhan
  • 407
  • 1
  • 9
  • 18

1 Answers1

1

Grid generally manages distribution of test case execution on it's own. If both nodes are of the same configuration, Grid will send a test to each node, then as these first tests complete, another test will be sent, repeated until the suite is complete. Depending on the length of your tests, this could in fact result in two tests on each node being executed. If tests vary in length, you could possibly end up with a 3/1 scenario. Even if that's the case though, it wouldn't create any technical difference so long as the nodes are the same (as you stated, they are).

Unless you have a specific purpose in mind for why which tests get executed on which node, Grid pretty much handles all the work of dividing the work among the resources it has at its disposal.

I know this info is somewhat generic, but if you have a specific requirement, please update your question and we'll all be able to help you better.

tim-slifer
  • 1,068
  • 1
  • 9
  • 17
  • 1
    Let me give an example: Suppose I have 2 node on the same grid: one is 1 instance of FF and the other one is an android device. In my tests I use 2 drivers: one for the FF and the other for the android. If the grid's node are not align with the order of the driver's initialization, I will get an error. "org.openqa.selenium.WebDriverException: The path to the driver executable must be set by the webdriver.ie.driver system property;". So the question is how do I tell the driver to route to the right node? – Eyal Sooliman Jul 01 '15 at 11:27