Overview of Selenium Architecture
Presently, Selenium is one of the most popular tools for automation in the market. It is a very powerful tool and is widely used. One of the reasons for its popularity is that it is free i.e, it is an open source testing suite. Its popularity is not just a result of this but many more reasons. It is an automation tool for web applications and supports all the different browser like Internet Explorer, Chrome, Safari, Mozilla Firefox, Opera, etc. It extends support to different platforms along with various programming languages such as C#, Java, Perl, PHP, Python, Ruby. Selenium is somewhat similar to the UFT tool (HP Quick Test Pro or QTP). The main difference is that Selenium is dedicated to the automation of web-based applications only. If you use Selenium for testing than it is known as Selenium Testing.
Remember that Selenium is an open source Web UI (User Interface) suite for automation testing. It has much software which independently caters to the requirements of an automation tester in an organization. The tool was developed at thought works by Jason Huggins in 2004 as an internal tool. Selenium supports several different platforms like Windows, Linux, Solaris, and Macintosh. It also supports OS (Operating System) for mobile applications such as windows mobile and android mobile, iOS. All the functional tests can be automated and carried out using Selenium easily. In order to achieve continuous testing, it can also be integrated with other test tools for automation like Maven, Docker, Jenkins, etc. As selenium is incapable of generating test reports on its own, it should be integrated with tools like JUnit or TestNG in order to manage test cases and generate reports which are well descriptive and configurable as per our requirements.
The four main architecture of Selenium are listed below –
- Selenium IDE
- Selenium RC
- Selenium Webdriver
- Selenium Grid
The role of a server here is in launching and killing the browser, receiving and verifying HTTP requests made between the browser and the application under test, interpreting and executing the Selenese commands passed by the test program and also acting as an HTTP proxy. The Client Libraries, however, act as an interface between the Selenium RC server and different programming languages being used.
4.5 (2,711 ratings)
The methodology of Client-Server architecture of RC, with Selenium RC between the Automation Suite and AUT(Application Under Test), makes the execution of scripts slower. This is taken care of by the Selenium Webdriver as it communicates directly to the AUT and makes use of the browser’s natural compatibility to automation without the requirement of any server.
3)Selenium WebDriver is the most popular and important component of Selenium. It is one of the most popular automation tools on which presently several Automation Engineers rely. The tool is an “Open Source tool” i.e, it is available for free.
WebDriver is an improved version of Selenium RC extending its support to different browsers and platforms, unlike Selenium IDE. The execution of test scripts does not require any Selenium server to be started, unlike the Selenium RC. Selenium Webdriver is basically a web-based test automation tool API that is easy to understand and use. It also supports the testing of dynamic web pages. Selenium Webdriver helps in creating and maintaining the test scripts in a very simple way as it is not linked to any test framework or tool. This makes it easy to integrate with any open source tools like Junit, TestNG, etc as per our knowledge, requirement, and usage.
4)Selenium Grid is one of the components of the Selenium Suite which supports execution of multiple test scripts across various different browsers or operating system or machines. After specifying the operating system of your choice along with the browser and the browser version, the selenium grid can be easily connected with the Selenium Remote. These values can only be specified based on the capabilities of the Selenium Remote being used.
Hub and nodes are its two main components. To be able to use the Selenium Grid tool, the very first step to perform is creating a hub. After a hub is created, several different nodes can be connected to this hub. The test scripts are executed in the node. The function of the hub, however, is to make sure the test will end up correctly on the specifications provided such as the details of the machine, operating system and the browser specified in your test.
To conclude, Selenium is basically a suite of tools namely, IDE, a Firefox extension that allows record and playback features. The record/playback feature is limiting and only available for Firefox, so the second tool is the RC with Webdriver(third tool) as its extension that provides APIs in different languages and browser compatibility. At last, the Grid is responsible for making parallel execution of scripts in different browsers and machines possible.
This has been a guide to Selenium Architecture. Here we discuss the introduction and top 4 architecture of selenium. You can also go through our other suggested articles to learn more –