What is Selenium?
Selenium is an open-source web browser automation tool. It provides a single interface for writing test scripts in a variety of programming languages, including Ruby, Java, NodeJS, PHP, Perl, Python, and C#.
The scripts are then executed by a browser driver on a browser instance on your device (more on this in a moment).
Selenium WebDriver
WebDriver, also known as Selenium 2.0, runs test scripts using browser-specific drivers. It consists of the following components:
API
API stands for an application programming interface. Through bindings, it converts test scripts written in Ruby, Java, Python, or C# to Selenese (Selenium's scripting language).
Library
This folder contains the API as well as language-specific bindings. Although there are numerous third-party bindings available to support various programming languages, the main project supports the following client-side bindings: Selenium Java (as selenium jar files), Selenium Ruby, Selenium .NET (or Selenium C#, available as.dll files), Selenium Python, and Selenium JavaScript (Node).
Driver
This is an executable module that starts a browser and executes the test script. For example, Google creates and supports Chromedriver for Selenium to facilitate automation on Chromium/Chrome.
Framework
Selenium with Cucumber or Selenium with TestNG are examples of support libraries for integration with natural or computer language test frameworks.
Selenium Grid
By simultaneously performing many test scripts on any number of distant devices, the Grid can reduce test runtime. Parallel testing is the term for this.
Selenium Grid is a smart server that sends test commands to distant browser instances. Other than the client-side/test tester's script, the following are the two essential components required:
The Hub(server):
· Access requests from the WebDriver client are accepted. JSON test commands are routed to remote drivers on 'nodes' that have been registered.
Node (remote device):
· A native OS, browsers, and remote web driver are all included.
You define the 'desired capabilities' (device, platform, browser, etc.) of the node where the test will run in your test script. The Hub gets this script, searches the list of registered nodes for one that has the appropriate capabilities, and assigns the test to it to perform.
Selenium IDE
Selenium IDE is a Chrome and Firefox plugin that can log 'natural' browser interactions and create code in programming languages such as C#, Java, Python, and Ruby, as well as Selenium's scripting language, Selenese.
Within the IDE, testers may enable recording and play out the test scenario in the browser. After then, the IDE may repeat those interactions and flag any problems in red throughout the replay.
Know more: Automation
complicated to utilize in automation test scripts. So use it for fast prototyping, but Selenium WebDriver is recommended for more serious cross-browser testing.
Comments
Post a Comment