Selenium IDE

Selenium IDE

Selenium IDE

Selenium IDE (Integrated Development Environment) is an open source web automation testing tool under Selenium Suite. Unlike Selenium WebDriver and RC, it does not require any programming logic to write your test scripts, instead, you can simply record your interactions with the browser to create test cases. Afterward, you can use the play option to rerun the test cases.

It is a Firefox add-on that creates tests very quickly through its recording and playback functionality. This feature is similar to that of QTP. It is easy to install and easy to learn. Due to its simplicity, the Selenium IDE should be used only as a prototyping tool, not as a general solution for the development and maintenance of complex test sets. Although you can use the Selenium IDE without prior programming knowledge, you must least be familiar with HTML, JavaScript and the DOM (Document Object Model) to use this tool to its full potential. Knowledge of JavaScript will be necessary when we get to the section on the “runScript” command of Selenese.

The Selenium IDE supports auto-fill mode when creating tests. This feature serves two purposes:

  • It helps the tester to insert commands more quickly.
  • The user restricts the user to insert invalid commands.

Get Selenium 100% Practical Training

Feature of Selenium IDE

  • Easy recording and playback
  • Autocomplete for all common Selenium commands
  • Examine tests
  • Debug and define breakpoints
  • Save tests such as HTML, Ruby, Python, C # scripts or any other format
  • Support for the Selenium user-extensions.js file
  • Option to automatically assert the title of each page
  • Easy customization through plug-ins

Selenium IDE Commands (Selenese)

There are three types of Selenium IDE commands:

Actions

Actions are commands that generally manipulate the state of the application. They do things like write that box, click on that link or select the option. If an action fails or has an error, the execution of the current test is interrupted. Many actions can be called with the suffix AndWait, for example. click OnWait, typeAndWait. This Suffix informs Selenium that the action will cause the browser to make a call to the server and that Selenium waits for a new page to load.

Accessors

Accessors These commands examine the status of the application and store the result in variables, such as storeTitle. They are also used to generate assertions automatically. Affirmations These commands are like accessors, but they check if the status of the application is in accordance with what was expected.

 Assert

  • Check: when a “Check” fails, the test will continue execution, recording the failure.
  • WaitFor: Wait for some condition to become true. They will be successful immediately if the condition is already true. However, it will fail and interrupt the test if the condition does not become true within the current timeout setting.

Disadvantages of Selenium IDE

  • Does not support loop or conditional statements. The tester needs to use native languages to write the logic in the test case.
  • It does not support the test report, you have to use the selenium RC with some external report form such as TestNG or JUnit to obtain the test execution report.
  • The treatment of errors is also not compatible, depending on the native language for it.

Related Blogs