About Grid,Hub,Node,BrowserDriver

Why we need Grid?

When we want to improve the speed of automation test,  we hope the test cases can run on multiple computers at the same time, we call it "concurrent execution",  so we need Grid.web

What is Grid?

  • In Grid mode, there is one Hub and multiple Nodes.
  • Hub run on a single computer, each Node run on a single computer.
  • Each Node points to the Hub by the hostname and port of the Hub.

How to set up the Grid environment?

To set up the Grid environment, we only need to write several files to the computers which are used as Hub and Nodes:ide

  1. Config the Nodes infomation into AllNodes.bat:                                                                If you want to build the Hub and Node environment on you local computer or other computers, you must modify the configuration in AllNodes.bat.                                  Both the HUD_NAME and DRIVER_PATH in AllNodes.bat need to be modified according to the actual condition.
  2. Config the Hub information into Hub.bat:
  3. Run Hub.bat on Hub firstly, then run AllNodes.bat on Nodes.

What is Browserdriver?

Webdriver is provided by browser company, if we want to operate Browser by software program, we need Browser Webdriver to driver it.ui

We only need to provide webdriver for Chrome and IE , because the Webdriver for Firefox has been integrated to Browser.spa

Grid we are using

If you wanna see the Grid Console which you are using,  enter "http://Hub_Name:Hub_Port/grid/console#" in the URL and open it. For example:orm

That means:ip

  1. There are 7 Nodes under the Hub "SZMERCURYTEST1".
  2. Each Node has 4 kinds of WebDrivers, includes :Safari, Chrome, Firefox, IE
  3. When the browser has been used to run test case, the icon of it will become gray.
相關文章
相關標籤/搜索