1.在fire fox上安装selenium IDE
打开fire fox
点击“附加组件”
点击“查看更多组件”
搜索“selenium ide”
选择“Selenium IDE Button”,添加到fire fox
重启fire fox
2.录制
打开fire fox
点击“开发者”
点击“selenium ide”
此时就可以操作网页,做需要录制的操作
录制完成后,停止录制
3.保存成Python脚本
在步骤2打开的selenium IDE中点击“文件”
选择“Export Test Case As”
选择Python2/unittest/webdriver
保存成.py的文件