步骤:
1.下载ruby的安装包:http://www.ruby-lang.org/zh_CN/downloads/
下载Windows一步安装版,默认安装(需要安装在系统所在盘,如:C盘)
安装成功可以运行命令查看版本:ruby –v
RUBY程序测试
2.安装watir(网络安装)
1、运行命令先更新gem:gem update –system
2、运行命令安装watir: gem install watir
安装成功后在Ruby193lib
ubygems1.9.1gems有watir
3.更新已安装的gem
运行命令先更新gem:gem update
4. https://github.com/oneclick/rubyinstaller/wiki/development-kit下载
下载安装devkit-tdm....exe,双击解压缩
切换到此目录下执行ruby dk.rb init
ruby dk.rb review
ruby dk.rb install
gem install watir
安装watir-webdriver
在cmd窗口键入下面命令进行watir-webdriver安装
5. WatirRecorder++(watir脚本录制工具,可选)
1、安装.net framework 1.1版本:
下载地址:http://download.microsoft.com/download/7/b/9/7b90644d-1af0-42b9-b76d-a2770319a568/dotnetfx.exe
2、安装WatirRecorder++
下载:http://www.hanselman.com/blog/content/binary/WatirRecorder_Setup_lite.msi
6. 安装IE Developer Toolbar(IE插件,可选)
下载地址:http://www.microsoft.com/downloads/details.aspx?familyid=e59c3964-672d-4511-bb3e-2d5e1db91038&displaylang=en