Selenium IDE is the easiest open source test automation tool. There are some limitation in Selenium IDE, however it can be effectively used for functional testing of Web Applications. It is best suited during integration phase of testing.
Before going into Selenium we will check the need of Automation Testing over Manual Testing
Why Should I Automate ?
- It reduces the rerunning of test against the new release to ensure that all previous changes done are un-changed
- Automation tool can be used for Load Testing, Performance Testing where if we need to test the performance or load over 10,000 user it can be easily automated
- It saves time, money and also increases the accuracy
- It also can be useful to developer to quick check any module before sending it to QA team
What is Selenium ?
- Selenium is a set of tools for development of Automation application for Web based application
Main Components of Selenium Testing Tool
- Selenium IDE
- Selenium RC
- Selenium Grid
Selenium IDE
- Selenium IDE basically works on ‘record and play‘ functionality. Where we can record the test script and play it
- Selenium IDE is used to build up automated test cases
- Selenium IDE is an open source Add-On for Mozilla Firefox
- The script format in Selenium IDE can be written in various language like C#, Java, PERL, Python, HTML
- Selenium IDE can be installed from the official page of selenium http://seleniumhq.org/download/
Steps for Installing Selenium IDE and record and play script
- Once the Selenium is downloaded in Firefox following window will appear, on successful installation the successful installation will be displayed and one need to restart the browser to use the tool
- After restarting the browser, one can see the Selenium IDE in Tools
- On clicking the Selenium IDE it will launch the tool. By default the tool will be in record mode where one can start recording as soon as the tool is opened. Red button in right most corner is used to Start and Stop recording.
- One can reduce or increase the speed on running script. Either one can run entire single test case or run entire test suite. Where Test Suite is collection of multiple test cases
- To start recording simply start the tool, start recording the desired script. Here consider the simple example
- Start Selenium IDE
- Minimize the tool and enter www.google.com
- After that type Selenium and click on Search
- Select the first record that is searched
- Now Stop the recording and Save it with .html extension
- Once Test Case is saved, play that Script
- One can also view the source code of recorded script which will appear as given below
- Selenium not only works on record and play functionality but also can be useful in removing the failure in the script. For example if we add extra command that does not exist in the original script it will give Failure
- We can insert various command like ClickAndWait, Start Point, Break Point, Verify Text etc
- The main limitation of Selenium IDE is that it cannot be used with other browsers. It is available as add on only for Mozilla Firefox. But for other browsers Selenium RC or Selenium Web driver can be used.