2
Most read
4
Most read
SeleniumGrid
By Mithilesh Singh
Pointsto be
remembered:
• It is a component of the
Selenium which is use to
execute the scenarios
remotely.
Note:What is meant by
Remotely?
To execute the scenarios on
the machine/system which is
not physically
present(known as Virtual
machine).
• Grid follows two concept--
Hub(Master) and
Node(slave)
Note:We can create one Hub
and multiple nodes.
Pre-requisites:
1. We should have drivers and
browsers on local and
remote systems.
2. we need to make our local
system as Hub and register
all the VM in Hub as a node.
3. Write test case then execute
on remote systems.
Basic Terminology Of
SeleniumGrid:
• Hub: Hub is the central point to the
entire GRID Architecturewhich
receives all requests.There is only
one hub in the selenium grid. Hub
distributes the test cases across each
node.
• Node: There can be multiple nodes
in Grid. Tests will run in nodes. Each
node communicateswith the Hub
and performs test assigned to it.
Steps to
convert any
device(system)
as HUB.
1. Install the standalone application in device
and Navigate to the location where
standalone jar is installed and type cmd
in file path section and click enter.
2. use this command to make local machine
as hub: java -jar selenium-server-
standalone-3.141.59.jar -role hub
• check hub is running using below url:
http://localhost:4444/grid/console
Note: If we do not specify the port then
selenium grid server will up at 4444 and
node would up at 5555 by default. To
specify the port we can use –port with
above command.
java -jar selenium-server-standalone-
3.141.59.jar -role hub –port <port number>
Register node with the hub server:
To convert any machine as a node we haveto downloadthe stand aloneselenium jar to that machine
and need to navigateto that location.
Then open the cmd and use below command
e.g.
java -Dwebdriver.chrome.driver=C:Driverschromedriver_win32chromedriver.exe"-jar selenium-
server-standalone-3.141.59.jar -role node -hub http://localhost:4444/grid/register
Note: we can mention the port no. also in above command like –port <port number> or else node
would be registerat default port 5555.
We can use below command also in case above one is not working.
java -
Dwebdriver.chrome.driver="C:Usersmithilesh.singhDownloadschromedriver_win32chromedrive
r.exe" -jar selenium-server-standalone-3.141.59.jar -port 4460 -role node -hub
http://localhost:4444/grid/register -browser "browserName=chrome,platform=WINDOWS,
maxInstances=10"
Implement code
to execute
scenarioson
node(Registered
with hub):
As in the example,you have to use RemoteWebDriverif
you are using the GRID and you have to provide
capabilities to the browser.You have to set the
browser and platformas below.
String nodeURL="http://192.168.13.1:5555/wd/hub";
DesiredCapabilities cap = DesiredCapabilities.chrome();
cap.setBrowserName("chrome");
cap.setplatform(Platform.WIND10);
System.setProperty("webdriver.chrome.driver","C://Drive
rs//chromedriver_win32//chromedriver.exe");
driver=new RemoteWebDriver(new URL(nodeURL), cap);
Note: Restother things will be same in the framwork.
MithileshSingh

More Related Content

PDF
Introduction to Selenium grid
PDF
Selenium grid workshop london 2016
PPTX
Selenium WebDriver- Training Material and QA
PDF
How to use Selenium Grid for Multi-Browser Testing.pdf
PDF
Introduction to selenium_grid_workshop
PPTX
How to work with Selenium Grid: a quick walkthrough
KEY
Selenium Grid
PDF
Meet the Selenium Grid
Introduction to Selenium grid
Selenium grid workshop london 2016
Selenium WebDriver- Training Material and QA
How to use Selenium Grid for Multi-Browser Testing.pdf
Introduction to selenium_grid_workshop
How to work with Selenium Grid: a quick walkthrough
Selenium Grid
Meet the Selenium Grid

Similar to Selenium_Grid (20)

PDF
The Selenium Grid: Run Multiple Automated Tests in Parallel
PDF
Cross Browser Testing using Selenium GRID.pdf
PDF
Cross Browser Testing using Selenium GRID
PPTX
Cross platform browser automation tests sdp
PPTX
How to work with Selenium Grid and Cloud Solutions
PPTX
SKILLWISE_SELENIUM
PPTX
Get Started With Selenium 3 and Selenium 3 Grid
PPTX
Scaling and Managing Selenium Grid
PPT
Running Selenium tests on CI server
PPTX
Autoscaled Distributed Automation Expedia Know How
PDF
Selenium
KEY
Getting started with Selenium 2
ODP
Mastering selenium for automated acceptance tests
PPTX
Autoscaled Distributed Automation using AWS at Selenium London MeetUp
PPTX
Distributed Automation(2018) - London Test Automation in Devops Meetup
PPTX
Selenium 101 Webinar
PPTX
Selenium for Jobseekers
PPTX
Selenium And Its Types
PPTX
PPTX
Kubernetes your tests! automation with docker on google cloud platform
The Selenium Grid: Run Multiple Automated Tests in Parallel
Cross Browser Testing using Selenium GRID.pdf
Cross Browser Testing using Selenium GRID
Cross platform browser automation tests sdp
How to work with Selenium Grid and Cloud Solutions
SKILLWISE_SELENIUM
Get Started With Selenium 3 and Selenium 3 Grid
Scaling and Managing Selenium Grid
Running Selenium tests on CI server
Autoscaled Distributed Automation Expedia Know How
Selenium
Getting started with Selenium 2
Mastering selenium for automated acceptance tests
Autoscaled Distributed Automation using AWS at Selenium London MeetUp
Distributed Automation(2018) - London Test Automation in Devops Meetup
Selenium 101 Webinar
Selenium for Jobseekers
Selenium And Its Types
Kubernetes your tests! automation with docker on google cloud platform
Ad

More from Mithilesh Singh (20)

PPTX
End2EndTesting_With_GenerativeAI - ChatGPT
PPTX
GITHUB_ACTIONS_CICD_OVERVIEW_FOR_BEGINNERS
PDF
Cucumber Basics.pdf
PDF
Data Migration.pdf
PDF
SDLC Models.pdf
PDF
Test_Case_Design_Techniques
PDF
Performance Testing
PDF
Software_requirement_collection
PDF
Stub_&_Drive
PDF
Functional_Testing_Part-1
PDF
TestersMindSet 2022
PDF
API_Testing_with_Postman
PDF
Agile_basics
PDF
Appium_set_up
PDF
Appium- part 1
PDF
Alpha & Beta Testing
PDF
Severity and Priority
PDF
GIT_Overview.
PPTX
Selenium-Locators
PDF
Browser_Stack_Intro
End2EndTesting_With_GenerativeAI - ChatGPT
GITHUB_ACTIONS_CICD_OVERVIEW_FOR_BEGINNERS
Cucumber Basics.pdf
Data Migration.pdf
SDLC Models.pdf
Test_Case_Design_Techniques
Performance Testing
Software_requirement_collection
Stub_&_Drive
Functional_Testing_Part-1
TestersMindSet 2022
API_Testing_with_Postman
Agile_basics
Appium_set_up
Appium- part 1
Alpha & Beta Testing
Severity and Priority
GIT_Overview.
Selenium-Locators
Browser_Stack_Intro
Ad

Recently uploaded (20)

PDF
How to Make Money in the Metaverse_ Top Strategies for Beginners.pdf
PDF
Top 10 Software Development Trends to Watch in 2025 🚀.pdf
PDF
The Dynamic Duo Transforming Financial Accounting Systems Through Modern Expe...
PDF
Topaz Photo AI Crack New Download (Latest 2025)
PDF
Product Update: Alluxio AI 3.7 Now with Sub-Millisecond Latency
PPTX
Advanced SystemCare Ultimate Crack + Portable (2025)
PDF
Time Tracking Features That Teams and Organizations Actually Need
PPTX
assetexplorer- product-overview - presentation
PDF
Designing Intelligence for the Shop Floor.pdf
PDF
AI Guide for Business Growth - Arna Softech
PPTX
Introduction to Windows Operating System
PPTX
Computer Software - Technology and Livelihood Education
PPTX
CNN LeNet5 Architecture: Neural Networks
PDF
EaseUS PDF Editor Pro 6.2.0.2 Crack with License Key 2025
PDF
MCP Security Tutorial - Beginner to Advanced
PPTX
AMADEUS TRAVEL AGENT SOFTWARE | AMADEUS TICKETING SYSTEM
PDF
Wondershare Recoverit Full Crack New Version (Latest 2025)
PDF
How AI/LLM recommend to you ? GDG meetup 16 Aug by Fariman Guliev
PPTX
"Secure File Sharing Solutions on AWS".pptx
PDF
CCleaner 6.39.11548 Crack 2025 License Key
How to Make Money in the Metaverse_ Top Strategies for Beginners.pdf
Top 10 Software Development Trends to Watch in 2025 🚀.pdf
The Dynamic Duo Transforming Financial Accounting Systems Through Modern Expe...
Topaz Photo AI Crack New Download (Latest 2025)
Product Update: Alluxio AI 3.7 Now with Sub-Millisecond Latency
Advanced SystemCare Ultimate Crack + Portable (2025)
Time Tracking Features That Teams and Organizations Actually Need
assetexplorer- product-overview - presentation
Designing Intelligence for the Shop Floor.pdf
AI Guide for Business Growth - Arna Softech
Introduction to Windows Operating System
Computer Software - Technology and Livelihood Education
CNN LeNet5 Architecture: Neural Networks
EaseUS PDF Editor Pro 6.2.0.2 Crack with License Key 2025
MCP Security Tutorial - Beginner to Advanced
AMADEUS TRAVEL AGENT SOFTWARE | AMADEUS TICKETING SYSTEM
Wondershare Recoverit Full Crack New Version (Latest 2025)
How AI/LLM recommend to you ? GDG meetup 16 Aug by Fariman Guliev
"Secure File Sharing Solutions on AWS".pptx
CCleaner 6.39.11548 Crack 2025 License Key

Selenium_Grid

  • 2. Pointsto be remembered: • It is a component of the Selenium which is use to execute the scenarios remotely. Note:What is meant by Remotely? To execute the scenarios on the machine/system which is not physically present(known as Virtual machine). • Grid follows two concept-- Hub(Master) and Node(slave) Note:We can create one Hub and multiple nodes. Pre-requisites: 1. We should have drivers and browsers on local and remote systems. 2. we need to make our local system as Hub and register all the VM in Hub as a node. 3. Write test case then execute on remote systems.
  • 3. Basic Terminology Of SeleniumGrid: • Hub: Hub is the central point to the entire GRID Architecturewhich receives all requests.There is only one hub in the selenium grid. Hub distributes the test cases across each node. • Node: There can be multiple nodes in Grid. Tests will run in nodes. Each node communicateswith the Hub and performs test assigned to it.
  • 4. Steps to convert any device(system) as HUB. 1. Install the standalone application in device and Navigate to the location where standalone jar is installed and type cmd in file path section and click enter. 2. use this command to make local machine as hub: java -jar selenium-server- standalone-3.141.59.jar -role hub • check hub is running using below url: http://localhost:4444/grid/console Note: If we do not specify the port then selenium grid server will up at 4444 and node would up at 5555 by default. To specify the port we can use –port with above command. java -jar selenium-server-standalone- 3.141.59.jar -role hub –port <port number>
  • 5. Register node with the hub server: To convert any machine as a node we haveto downloadthe stand aloneselenium jar to that machine and need to navigateto that location. Then open the cmd and use below command e.g. java -Dwebdriver.chrome.driver=C:Driverschromedriver_win32chromedriver.exe"-jar selenium- server-standalone-3.141.59.jar -role node -hub http://localhost:4444/grid/register Note: we can mention the port no. also in above command like –port <port number> or else node would be registerat default port 5555. We can use below command also in case above one is not working. java - Dwebdriver.chrome.driver="C:Usersmithilesh.singhDownloadschromedriver_win32chromedrive r.exe" -jar selenium-server-standalone-3.141.59.jar -port 4460 -role node -hub http://localhost:4444/grid/register -browser "browserName=chrome,platform=WINDOWS, maxInstances=10"
  • 6. Implement code to execute scenarioson node(Registered with hub): As in the example,you have to use RemoteWebDriverif you are using the GRID and you have to provide capabilities to the browser.You have to set the browser and platformas below. String nodeURL="http://192.168.13.1:5555/wd/hub"; DesiredCapabilities cap = DesiredCapabilities.chrome(); cap.setBrowserName("chrome"); cap.setplatform(Platform.WIND10); System.setProperty("webdriver.chrome.driver","C://Drive rs//chromedriver_win32//chromedriver.exe"); driver=new RemoteWebDriver(new URL(nodeURL), cap); Note: Restother things will be same in the framwork.