Selenium
Selenium | |
---|---|
Basic data
|
|
developer | ThoughtWorks |
Publishing year | 2004 |
Current version |
3.141.59 ( December 19, 2018 ) |
operating system | Microsoft Windows , Linux , macOS , Solaris , FreeBSD and other Unix variants (based on Java ) |
programming language | Java |
License | Apache license 2.0 |
selenium.dev |
Selenium is a framework for automated software testing of web applications , which was developed by a programming team from ThoughtWorks and published as free software under the Apache 2.0 license . It is a widely used tool and one of the most popular open source testing tools.
With Selenium it is possible to record interactions with a web application and to automatically repeat these tests as often as required. Above all, it can relieve web application developers a lot of typing - for example when filling out web forms - and thus makes testing faster, more flexible and more reliable.
Selenium is based purely on HTML and JavaScript . For a quick start, the Selenium IDE can be used . B. be installed and tested as a Firefox add-on: the user only interacts with Firefox, Selenium records the test and plays it back.
history
Jason Huggins founded Selenium in 2004 when he wrote an internal program for testing websites at his company ThoughtWorks . Over time, more and more ThoughtWorks employees joined his work, until Paul Hammant finally joined the team and led the development of the program in the direction of today's Selenium Remote Control (RC).
In 2007, Huggins moved to the software company Google , where he drove the further development and bug fixes of the program together with other programmers. At the same time, Simon Stewart developed the browser control Webdriver at ThoughtWorks. Since it did not seem sensible for the developers of both projects to advance two separate projects, they decided to combine the two projects into "Selenium Webdriver" or "Selenium 2.0".
In 2008 Philippe Hanrigou developed "Selenium Grid", which allows several Selenium instances to run simultaneously on an unlimited number of computers. As a result, the execution time for large test structures was dramatically reduced.
The name Selenium came from a joking remark by Huggins, who in an email mocked his competitor Mercury by mentioning that mercury poisoning can be cured by taking Selenium .
Versions
Selenium 3
The final version 3.0 has been available since October 13, 2016. The following changes or innovations are included there:
- Java
- minimum version is Java 8.
- WebDriver users
- Error corrections and simple updates from version 2.x possible.
- Selenium Grid users
- Error corrections and simple updates from version 2.x possible.
- WebDriver APIs
- only these APIs are still supported.
- Selenium RC APIs
- no more support; Part of a "legacy" package.
- Firefox support
- Starting with Firefox 47.0.1, Mozilla's GeckoDriver is required.
Components
Selenium Core
The core module contains the complete basic functionality of Selenium, i.e. the test command API and the TestRunner. Using the core module, the TestRunner.html website can be opened with different browsers. This enables compatibility tests with different browser types.
Selenium IDE
Selenium IDE is an add-on for Google Chrome and Mozilla Firefox , with which it is possible to record test cases directly in the browser by interacting with a web application and to play them back in the browser. In addition to the pure capture-replay functionality, checks can be integrated using verify and assert. In addition, the step-by-step playback of test cases, the setting of breakpoints to check the test cases, and the reuse of shared test procedures are supported. Individual test cases can be combined to form test suites.
Selenium Remote Control (RC) (obsolete)
RC is an outdated module that provides its own server instance in the form of a proxy . This Selenium server is controlled remotely by a Selenium client driver. This can be done in different programming languages, such as B. in Java , .NET , Perl , PHP , Python , Ruby . With Java, these test cases can be executed using JUnit or TestNG, for example . It enables test automation of GUI tests in combination with continuous integration .
With the release of Selenium 2, Selenium RC was replaced by Selenium WebDriver and marked as deprecated, with the release of Selenium 3, RC was moved to a ' legacy ' package and is no longer available for download on the project's main page.
Selenium WebDriver
Selenium WebDriver is the successor to Selenium Remote Control. It accepts commands (in Selenese or via the client API) and forwards them to a browser. HtmlUnit is a special feature . As of version 3.0, HtmlUnit is no longer part of the WebDriver. This is a web browser without a graphic display (headless). The Selenium WebDriver is implemented via a browser driver, whereby the most common browsers are supported.
Selenium Grid
Selenium Grid is an extension of Selenium RC and enables the parallel execution of tests on several servers in order to shorten the duration of the test execution. The Selenium client driver connects to the Selenium Hub component instead of the Selenium server. The hub in turn forwards the tests to free Selenium servers. Existing test cases for Selenium RC can also be used with Selenium Grid with minor changes. However, the test cases must be executed in parallel, e.g. B. with TestNG .
Use of Selenium
Various software products in the testing environment are based on Selenium, e.g. B .:
- Protractor , an end-to-end test framework for AngularJS applications,
- WebTester , a UI test automation framework
- Appium , an open source test automation tool for native and hybrid mobile applications (apps)
- BrowserStack , a cloud-based test platform for mobile and desktop internet applications
literature
- Michael Kain: Selenium. Automated testing of web applications , Open Source Press , ISBN 978-3-937514-57-4 .
- Unmesh Gundecha: Selenium 2 Cookbook , ISBN 978-1-84951-574-0 .
- David Burns: Selenium 2.0 Testing Tools: Beginner's Guide , ISBN 978-1-84951-830-7 .
- C. Titus Brown, Gheorghe Gheorghiu, Jason Huggins: An Introduction to Testing Web Applications with twill and Selenium , O'Reilly , ISBN 978-0-596-52780-8 .
- Alan John Richardson: Selenium Simplified, Compendium Developments , ISBN 978-0-9567332-1-4 .
- Selenium Testing Tools Interview Questions You'll Most Likely Be Asked , CreateSpace Independent Publishing, ISBN 978-1-4637-6813-3 .
Web links
- Official website
- List and news feed of all Selenium blogs
- Analysis and evaluation of the Selenium tool
Individual evidence
- ↑ Release 3.141.59 . December 19, 2018 (accessed December 20, 2018).
- ↑ Advanced seminar on web engineering
- ^ The Art of Unit Testing: German edition, page 290 Roy Osherove, Mitp-Verlag
- ↑ Alexander Neumann: Integration tests: Selenium 3 has appeared. In: Heise online - heise Developer. Heise Medien, October 14, 2016, accessed on February 1, 2017 : "one of the most widely used tools in web development"
- ↑ Automated test procedures for web-based applications (PDF; 944 kB) Oliver Fischer, master's thesis at the chair for data structures and software reliability at BTU Cottbus
- ↑ a b Selenium 3 is coming. October 4, 2016, accessed on October 15, 2016 (announcement of Selenium 3 in the developers' blog).
- ↑ Selenium homepage. Retrieved July 29, 2016 .