selenium-rc setup guide
For PCF web-based projects, automated test cases are run with Selenium-rc using the python extension.
You will need the following software tools:
1. Mozilla FireFox browser
2. Selenium IDE (http://seleniumhq.org/download/)
3. Selenium RC (http://seleniumhq.org/download/)
4. XPath Checker (https://addons.mozilla.org/en-US/firefox/addon/1095)
5. Python (http://www.python.org/download/releases/2.6.5/)
6. PythonWin, if you use Windows on your computer (http://sourceforge.net/projects/pywin32/)
For Selenium RC to run on your computer, you will also need to have Java installed and running (remember to check Java if you have trouble launching Selenium RC!).
Selenium IDE and XPath Checker install as plug-ins to FireFox.
To install and run Selenium RC:
1. Download and unzip the installation file from the list above.
2. Place selenium.py file to the /lib subfolder of your Python folder.
3. Run the following batch file from the selenium-server directory:
java -jar selenium-server.jar
Selenium RC will start in a console window.
Now you can launch PythonWin and start editing and running test scripts.
To produce a basic Python/Selenium script:
1. Launch FireFox and navigate to the desired page.
2. Through Tools menu, start Selenium IDE.
3. With the use of Record button, record the sequence of actions.
4. In Selenium IDE, select Options -> Format -> Python - Selenium RC command from the menu.
5. You will see a Python script in Selenium IDE window. Copy it and paste to a new script window in PythonWin. Save your script and click Run button.
Useful links:
http://seleniumhq.org/docs/05_selenium_rc.html
http://agiletesting.blogspot.com/2005/03/web-app-testing-with-python-part-2.html
http://release.seleniumhq.org/selenium-remote-control/1.0-beta-2/doc/python/
http://www.jroller.com/selenium/#installation
http://docs.python.org/library/unittest.html
http://diveintopython.org/toc/index.html
* Special thanks to maggie_s for putting all this information together.