Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Benefits:

  • Easy to install and use.

  • Light, powerful, shareable, helps in exporting tests

  • Has built-in help feature and it shows the documentation on the selected or entered command.

  • Helps in debugging by displaying the information and error messages.

  • It allows to set breakpoints, insert commands and comments wherever necessary.

  • Provides a good support for extensions.

Limitations:

  • Need to have specific elements or text appear on page to assert, verify

  • Records can be wrong or fail because of css change

  • Not suitable for testing extensive data

  • Incapable of handling multiple windows

  • Connections with the database can not be tested

  • Cannot handle the dynamic part of web-based applications

  • Does not support capturing of screenshots on test failures

  • No feature available for generating result reports

...

Get started:

(Document reference )

Run with CLI:

Install selenium-side-runner: yarn global add selenium-side-runner

Install web drivers:

  • Chrome: yarn add global chromedriver

  • Firefox: yarn add global geckodriver

  • Edge: yarn add global edgedriver

  • IE: yarn add global iedriver

Launching the runner: selenium-side-runner /path/to/your-project.side

Get more config

...

Simple tests with login page with google:

Step 1: Open selenium IDE on chrome and add a test case name Login

...

Step 2: Click Recording button and interact with the page.

Ex: I fill id and password for sign in page.

...

and each of your actions will be recorded in the IDE.

...

Step 3:

  • Simply import attachment file, then run tests

...

Playback your login record with button run all test/ run current test.

...

Cross-browser:

Save project and move file into folder test and run on terminal, ensure you installed Install selenium-side-runner and Install web drivers:

Code Block
selenium-side-runner -c browserName=chrome Path_Folder/test.side

Reference

webpage : https://selenium.dev/selenium-ide/

Docs : https://selenium.dev/selenium-ide/docs/en/introduction/getting-started

install for chrome : https://chrome.google.com/webstore/detail/selenium-ide/mooikfkahbdckldjjndioackbalphokd

...

Organizing your tests

Tests

You can add a new test by clicking the + symbol at the top of left side-bar menu 

Suites

Tests can be grouped together into suites.

...

Command-line Runner

https://selenium.dev/selenium-ide/docs/en/introduction/command-line-runner

Code Expert

Supported Exports

Currently, export to the following languages and test frameworks is supported.

  • C# NUnit

  • Java JUnit

  • JavaScript Mocha

  • Python pytest

https://selenium.dev/selenium-ide/docs/en/introduction/code-export

...

API Reference

Commands

https://selenium.dev/selenium-ide/docs/en/api/commands

  • open

  • click

  • echo - Prints the specified message into the third table cell in your Selenese tables. Useful for debugging.

  • run script

  • if ~ else

  • select

  • wait for element visible - Wait for a target element to be visible on the page.

  • execute script

    • Executes a snippet of JavaScript in the context of the currently selected frame or window. The script fragment will be executed as the body of an anonymous function. To store the return value, use the 'return' keyword and provide a variable name in the value input field.

Image Added

...

Intergrate with jenkins : After Test

Image Added