Skip to content

Commit f30b9ae

Browse files
committed
Add the ReadMe for Selenium IDE script conversion
1 parent dea79a8 commit f30b9ae

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

integrations/selenium_ide/ReadMe.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
## Converting Selenium IDE recordings into SeleniumBase test scripts
2+
3+
#### Intro:
4+
5+
[Selenium IDE](http://docs.seleniumhq.org/projects/ide/) is a tool that allows you to record and playback actions performed inside a web browser. It's available as a [downloadable Firefox extension](https://addons.mozilla.org/en-US/firefox/addon/selenium-ide/). Selenium IDE comes with an option to export recordings as various WebDriver test scripts, one of which is ``Python2/unittest/WebDriver``. Unfortunately, these natively-exported scripts tend to be very messy and don't run reliably. The purpose of this converter is to clean up and improve the scripts so that they can be used in production-level environments.
6+
7+
#### Step 1: Make a recording with Selenium IDE
8+
9+
![](https://cdn2.hubspot.net/hubfs/100006/selenium_ide_example_b.png "Selenium IDE example")
10+
11+
#### Step 2: Export your recording as a Python 2 Webdriver script
12+
13+
* ``File`` => ``Export Test Case As`` => ``Python 2 / unittest / WebDriver``
14+
15+
#### Step 3: Drop your exported file into the ``selenium_ide`` folder.
16+
17+
* Just copy & paste!
18+
19+
(The full path of the folder is ``SeleniumBase/integrations/selenium_ide``)
20+
21+
#### Step 4: Run ``convert_ide.py`` on the Python file
22+
23+
```bash
24+
python convert_ide.py [MY_TEST.py]
25+
```
26+
27+
You should see a [MY_TEST_SB.py] file appear in the folder. (``_SB`` is added to the file name so that the original file stays intact in case you still need it.)
28+
29+
#### Step 5: Enjoy your new clean & reliable SeleniumBase test script
30+
31+
* You can now copy your new SeleniumBase test script into your test suite. It's ready to be run!

0 commit comments

Comments
 (0)