How To Use Selenium IDE To Record Test Case Script

After install selenium IDE, you are eager to know how to use it. Now we will introduce each selenium IDE element and its function.

1. How To Use Selenium IDE To Record Test Case Script Steps.

  1. When you click the selenium IDE extension button icon to open it, it will list some useful links in the popup window.
  2. The links contain Record a new test in a new project, Open an existing project, Create a new project, Close Selenium IDE.
  3. When you click the Record a new test in a new project link, it will popup the name your new project dialog, you can input the project name ( for example TestSeleniumIDE ) in the textbox, click the OK button.
  4. Then it will prompt the Set your project’s base URL dialog, you should input the base URL ( for example https://www.google.com ) in the textbox.
  5. Now you can click the START RECORDING button to record test scripts in selenium IDE.
  6. It will open a Google Chrome or Firefox web browser to browse the base URL, and there is a selenium IDE status button at the web browser bottom right corner to show what action is the selenium IDE doing.
  7. At the same time, the Selenium IDE window is active also, there are a lot of menus/buttons in it. When you click the Stop button ( on the top right corner of the Selenium IDE window ), it will pop up the Name your new test dialog, you can input the test name ( Test_1 ) in the textbox, click the OK button to save it.
  8. Now you can see the test name in the Selenium IDE window left side project Tests panel.
    selenium ide window

2. Selenium IDE Window Function Introduction.

  1. Click the test name on the left side Tests panel, it will list all the interactions that the tester runs with the web browser on the right side Test Script Detail panel.
  2. Each interaction line contains 3 columns.
  3. The Command column shows the tester action such as open, set window size, click, type, send keys.
  4. The Target column shows the web element XPath or CSS selector value, selenium use this value to select related web element.
  5. The Value column shows the user input values in the web page element ( for example input java in the google.com search box ).
  6. Click each interaction line will display the interaction properties in the panel below the interaction line list, you can modify the content of the Command, Target, or Value.
  7. If you want to run the current test script, you can select the test name in the left panel then click the Run current test button ( a triangle button ) on the top left corner of the Test Script Detail panel.
  8. If you want to insert interaction lines in your current test script, you can click right-click the interaction line, then click the Insert new command menu item in the popup menu list.
  9. You can also click the REC button on the top right corner of the selenium IDE window to record more interactions to the current test script.
  10. You can find a lot of menu items when you right-click one interaction line in the Test Script Detail panel on the Selenium IDE window right side.
  11. The menu items contain Cut, Copy, Paste, Delete, Insert new command, Clear all commands, Toggle breakpoint, Play to this point, Record from here, Play from here.
  12. The menu item name is so straightforward, you can understand it easily.
  13. If you want to save the selenium test project, you can click the Save project button on the top right corner of the selenium IDE window, then it will popup a dialog, you can input the file name ( TestSeleniumIDE.side ) and select a folder to save the selenium IDE test project.
  14. You can click the Open project button on the selenium IDE top right corner to open an existing selenium IDE project.
  15. You can click the Create new project button on the selenium IDE top right corner to create a new selenium IDE project.
  16. You can click the Add new test button on the selenium IDE window left side Tests panel’s top right corner to add a new test to the current project.

Subscribe to receive more programming tricks.

We don’t spam!

Subscribe to receive more programming tricks.

We don’t spam!

Leave a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.